ipbr21054
Well-known Member
- Joined
- Nov 16, 2010
- Messages
- 5,738
- Office Version
- 2007
- Platform
- Windows
Hi,
I have the following code applied but fails to work.
I would like to run this exe file from within my userform.
The working icon on the desktop read the following info of which i have entered into my non working code.
Target "C:\Users\Ian\Desktop\RUN AS DATE APP\RunAsDate.exe" /movetime 01\03\2013 00:00:00 "C:\Program Files\EPC\epc.exe"
Start In "C:\Program Files\EPC"
The error message shows compileroor / syntax error
I have the following code applied but fails to work.
I would like to run this exe file from within my userform.
The working icon on the desktop read the following info of which i have entered into my non working code.
Target "C:\Users\Ian\Desktop\RUN AS DATE APP\RunAsDate.exe" /movetime 01\03\2013 00:00:00 "C:\Program Files\EPC\epc.exe"
Start In "C:\Program Files\EPC"
The error message shows compileroor / syntax error
Code:
Sub OpenEpc() Dim strProgramName As String
Dim strArgument As String
strProgramName = ""C:\Program Files\EPC""
strArgument = ""C:\Users\Ian\Desktop\RUN AS DATE APP\RunAsDate.exe" /movetime 01\03\2013 00:00:00 "C:\Program Files\EPC\epc.exe" "
Call Shell("""" & strProgramName & """ """ & strArgument & """", vbNormalFocus)
End Sub