VB中使用ANI鼠标指针,移动到控件无法显示?
Private Declare Function LoadCursorFromFile Lib "user32" Alias "LoadCursorFromFileA" (ByVal lpFileName As String) As LongPrivate Declare Function SetClassLong Lib "user32" Alias "SetClassLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Private Const GCL_HCURSOR = (-12)
Private hOldCursor As Long
Private Sub Form_Load()
Dim hNewCursor As Long
hNewCursor = LoadCursorFromFile("C:\Sword.ani")
hOldCursor = SetClassLong(hwnd, GCL_HCURSOR, hNewCursor)
End Sub
'----------------------------------------------
Private Sub Form_Unload(Cancel As Integer)
hOldCursor = SetClassLong(hwnd, GCL_HCURSOR, hOldCursor)
End Sub
VB中使用ANI鼠标指针,当鼠标移动到控件中无法显示其光标.除Label控可显示.....
什么原因呢?