Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Windows troubles
Message
De
02/05/2017 11:26:25
 
 
À
30/04/2017 17:13:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Divers
Thread ID:
01650702
Message ID:
01650771
Vues:
64
>?FOPEN("c:\windows\snippingtool.exe")
>returns -1 want to say the file cannot be opened
>
>please try this code and see if it works on your machine (any of these cannot work in mine PC)
>
>run/n snippingtool
>
>local m.myvar
>text to m.myvar noshow
>snippingtool
>endtext
>set safe off
>strtofile(m.myvar,"asupprimer.bat")
>
>
>
>DECLARE INTEGER ShellExecute IN SHELL32.DLL INTEGER nWinHandle,;
>                                            STRING cOperation,;
>                                            STRING cFileName,;
>                                            STRING cParameters,;
>                                            STRING cDirectory,;
>                                            INTEGER nShowWindow
>
>result = ShellExecute(0, "open", "cmd.exe","/c asupprimer.bat","",0)
>messagebox(result,0+32+4096,'',1000)
>
>
>
>result = ShellExecute(0, "open", "asupprimer.bat","","",0)
>messagebox(result,0+32+4096,'',1000)
>
>
>
>
>result = ShellExecute(0, "open", "c:\windows\system32\snippingtool.exe","","",1)
>messagebox(result,0+32+4096,'',1000)
>
>
>local oshell
>oshell=newObject("wscript.shell")
>oshell.run ("c:\windows\system32\snipppingtool.exe")
>
not work.
There is the obsession of blocking the automatic running of programs
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform