mtheriault2000
Well-known Member
- Joined
- Oct 23, 2008
- Messages
- 826
Hello
I'm trying to use a variable that hold a string in Shell string command. This shell is the command to take a snap picture over a given region and store the picture to a pre determined file name
***The code do compile***
The string variable is : StringAddress = "g:\testsnap\asnap1.jpg"
The following shell command will work
RetVal = Shell(("C:\Program Files (x86)\HyperSnap 7\HprSnap7.exe " & " -hidden -snap:x3602:y155:w1432:h830 -save:jpg g:\testsnap\asnap1.jpg"))
This one, with the stringaddress variable, wont work
RetVal = Shell("C:\Program Files (x86)\HyperSnap 7\HprSnap7.exe " & " -hidden -snap:x3602:y155:w1432:h830 -save:jpg " & StringAddress)
I'm loss. Any help appreciated
Martin
I'm trying to use a variable that hold a string in Shell string command. This shell is the command to take a snap picture over a given region and store the picture to a pre determined file name
***The code do compile***
The string variable is : StringAddress = "g:\testsnap\asnap1.jpg"
The following shell command will work
RetVal = Shell(("C:\Program Files (x86)\HyperSnap 7\HprSnap7.exe " & " -hidden -snap:x3602:y155:w1432:h830 -save:jpg g:\testsnap\asnap1.jpg"))
This one, with the stringaddress variable, wont work
RetVal = Shell("C:\Program Files (x86)\HyperSnap 7\HprSnap7.exe " & " -hidden -snap:x3602:y155:w1432:h830 -save:jpg " & StringAddress)
I'm loss. Any help appreciated
Martin