mbrown Posted October 1, 2007 Share Posted October 1, 2007 How can I execute an MSI file? Link to comment Share on other sites More sharing options...
Tasmania Posted October 1, 2007 Share Posted October 1, 2007 Function Reference ShellExecute -------------------------------------------------------------------------------- Runs an external program using the ShellExecute API. ShellExecute ( "filename" [, "parameters" [, "workingdir" [, "verb" [, showflag]]]] ) Parameters filename The name of the file to run (EXE, .txt, .lnk, etc). parameters [optional] Any parameters for the program. Blank ("") uses none. workingdir [optional] The working directory. Blank ("") uses the current working directory. verb [optional] The "verb" to use, common verbs include: open = (default) Opens the file specified. The file can be an executable file, a document file, or a folder edit = Launches an editor and opens the document for editing. If "filename" is not a document file, the function will fail print = Prints the document file specified. If "filename" is not a document file, the function will fail properties = Displays the file or folder's properties showflag [optional] The "show" flag of the executed program: @SW_HIDE = Hidden window @SW_MINIMIZE = Minimized window @SW_MAXIMIZE = Maximized window Return Value Success: Returns 1. Failure: Depends on RunErrorsFatal; see Remarks. Remarks After running the requested program the script continues. To pause execution of the script until the spawned program has finished use the ShellExecuteWait function instead. By default the script will terminate with a fatal error if the ShellExecute function fails. To set @error to 1 as an indication of failure, see AutoItSetOption. Related ShellExecuteWait, Run, RunErrorsFatal (Option), RunWait *** Will that work? Link to comment Share on other sites More sharing options...
GaryFrost Posted October 1, 2007 Share Posted October 1, 2007 Pretty vague questions, but an example would be. Run(@SystemDir & '\msiexec.exe /i my.msi /qn') SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
mbrown Posted October 1, 2007 Author Share Posted October 1, 2007 Yeah, I appreciate both replies. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now