![]() |
|
|
#1 (permalink) |
|
E & G
![]() ![]() |
Private Type RECT
left As Integer top As Integer right As Integer bottom As Integer End Type Private Type POINT x As Long y As Long End Type Private Declare Sub ClipCursor Lib "user32" (lpRect As Any) Private Declare Sub GetClientRect Lib "user32" (ByVal hWnd As Long, lpRect As RECT) Private Declare Sub ClientToScreen Lib "user32" (ByVal hWnd As Long, lpPoint As POINT) Private Declare Sub OffsetRect Lib "user32" (lpRect As RECT, ByVal x As Long, ByVal y As Long) Private Sub Form_Load() Command1.Caption = "Fareleri hapsedin" Command2.Caption = "Birak garibani be!" End Sub Private Sub Command1_Click() 'fare imlecini form içine hapsedelim Dim client As RECT Dim upperleft As POINT GetClientRect Me.hWnd, client upperleft.x = client.left upperleft.y = client.top ClientToScreen Me.hWnd, upperleft OffsetRect client, upperleft.x, upperleft.y ClipCursor client End Sub Private Sub Command2_Click() 'fareyi serbset birakalim ClipCursor ByVal 0& End Sub Private Sub Form_Unload(Cancel As Integer) 'yasagi kaldiralim.Yoksa form kapansa da devam eder. ClipCursor ByVal 0& End Sub |
|
|
|
![]() |
| Bu konunun kısa yolunu aşağıdaki sitelere ekleyebilirsiniz! |
| Konu Araçları | |
| Stil | |
|
|
Benzer Konular
|
||||
| Konu | Konuyu Başlatan | Forum | Cevaplar | son Mesaj |
| Kız Fareyi Yedii böğğğ... | Ghost | Korku | 13 | 27-08-2008 18:10 |
| fareyi sağ üst köşeye sürükLeyin xD | CanSu | Komik Resimler | 13 | 16-07-2008 21:59 |
| Form rengini kod ile degistirme | Gu4rD1aN | C ve C++ | 2 | 29-03-2008 18:11 |
| saydam form olusturma | qRaLL | Visual Basic | 0 | 29-02-2008 05:05 |
| Saydam Form | *MeLeK* | Delphi | 0 | 28-01-2008 12:19 |