Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Custom MouseIcon doesn't appear in EXE (VFP 5.0)
Message
De
27/05/1997 15:01:59
 
 
À
27/05/1997 13:52:40
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00033684
Message ID:
00033745
Vues:
51
Hello! I made some researshes and find out the solution. Here is code that might be useful for you: PUBLIC oform1 oform1=CREATEOBJECT("form1") oform1.Show() RETURN DEFINE CLASS form1 AS form Caption = "Form1" Name = "Form1" ADD OBJECT command1 AS commandbutton WITH ; Top = 72, ; Left = 96, ; Height = 29, ; Width = 94, ; Caption = "SetCursor", ; Name = "Command1" ADD OBJECT command2 AS commandbutton WITH ; Top = 144, ; Left = 96, ; Height = 29, ; Width = 94, ; Caption = "ResetCursor", ; Name = "Command2" PROCEDURE Init public currenthcurs,tempcurs,newhcurs,OCR_NORMAL OCR_NORMAL=32512 &&from winuser.h ENDPROC PROCEDURE command1.Click MyDir=space(255) declare Integer GetWindowsDirectory in Win32Api String @, Integer declare Integer CopyIcon in Win32Api Integer declare Integer LoadCursorFromFile in Win32Api String declare Integer SetCursor in Win32Api Integer declare SetSystemCursor in Win32Api Integer, Integer declare Integer GetCursor in Win32Api currenthcurs=GetCursor() tempcurs=CopyIcon(currenthcurs) len=GetWindowsDirectory(@MyDir,255) MyDir=left(MyDir,len)+"\System32\dinosaur.ani" && WindowsNT * Uncomment the next line and comment the previous line if running under * Windows 95, or set MyDir to the path to a valid .cur or .ani file. * MyDir=left(MyDir,len)+"\cursors\dinosaur.ani" && Windows95 newhcurs=LoadCursorFromFile(MyDir) =SetSystemCursor(newhcurs,OCR_NORMAL) ENDPROC PROCEDURE command2.Click =SetSystemCursor(tempcurs,OCR_NORMAL) ENDPROC ENDDEFINE Hope this help... Have a happy day Vladimir Shevchenko
* Human is a question asked by birth and answered by death. Machine is another kind of question with another kind of answer
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform