![]() ![]() Public Shared Function CreateCursor(ByVal bmp As Bitmap, ByVal xHotspot As Integer, ByVal yHotspot As Integer) As Cursorĭim pnt As IntPtr = Marshal.AllocHGlobal(Marshal.SizeOf(tmp))ĭim curPtr As IntPtr = CreateIconIndirect(pnt) ''' creates a custom cursor from a bitmap Public Shared Function DeleteObject(ByVal hObject As IntPtr) As Boolean ![]() Public Shared Function DestroyIcon(ByVal handle As IntPtr) As Boolean Private Shared Function CreateIconIndirect(ByVal iconInfo As IntPtr) As IntPtr ''' contains API + local functions for creating Me.Cursor = create.CreateCursor(img, 47, 41)Įnd Class Imports 'the parameters for CreateCursor are the image to use 'here's how to use a bitmap as a custom cursor Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |