Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ShellExecute Failing
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
ShellExecute Failing
Divers
Thread ID:
01025967
Message ID:
01025967
Vues:
63
I have the following code. It had worked forever with no problems.
Today I failed. The ShellExecute function is now returning 2.

How do I find out what this '2' represents?
LPARAMETERS cApplication, cStartFolder, cParamString

	LOCAL iRetVal

	IF EMPTY(cParamString)
		cParamString = ""
	ELSE
		cParamString = '"' + cParamString + '"'
	ENDIF

	IF EMPTY(cStartFolder)
		cStartFolder = ""
	ENDIF

	DECLARE INTEGER GetDesktopWindow IN WIN32API
	
	DECLARE INTEGER ShellExecute IN shell32; 
	    INTEGER hwnd,; 
	    STRING  lpOperation,; 
	    STRING  lpFile,; 
	    STRING  lpParameters,;   
	    STRING  lpDirectory,; 
	    INTEGER nShowCmd 

	hWnd = GetDesktopWindow()

	iRetVal = ShellExecute(hWnd, "open", cApplication, cParamString , cStartFolder, 5)

RETURN
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform