![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Jun 2008
Posts: 3
Rep Power: 0
![]() |
Hi
I'm using VB 2005 Express Edition. I must set the the cursor's position. For example, i created a cursor for the Current cursor's Handle, changes its position and clipping rectangle. I tried out the code, but there are several errors and warnings. Any help? Public Shared Property Position As Point
Public Class Form1
Dim value As Point
value = Cursor.Position
Cursor.Position = value
Private Sub MoveCursor()
' If the form's cursor is not the Default cursor,
' set the Current cursor, move the cursor's Position,
' and set its clipping rectangle to the form.
If Not Me.Cursor.Equals(Cursors.Default) Then
Me.Cursor = New Cursor(Cursor.Current.Handle)
Cursor.Position = New Point(Cursor.Position.X - 50, Cursor.Position.Y - 50)
Cursor.Clip = New Rectangle(Me.Location, Me.Size)
End If
End Sub
End ClassThe namespace is System.Windows.Forms. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| OpenCV Help Needed: Can't use the keyboard while running cvcamSetPropetry | Phanixis | C++ | 3 | May 15th, 2007 4:04 PM |
| Removing 'run' registry keys? | Prm753 | C | 9 | Jan 28th, 2007 4:35 PM |
| keyboard: switching scripts | EverLearning | Coder's Corner Lounge | 5 | Jul 22nd, 2005 9:04 PM |
| Keyboard guide needed | Aphex_Twin | C++ | 3 | May 21st, 2005 1:13 PM |
| Interfacing with a Keyboard | brkstf | Assembly | 7 | Mar 21st, 2005 4:48 PM |