Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Run (filename with spaces) ?
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00756665
Message ID:
00757178
Views:
13
Hi Andrew,
I'm hoping you found something I couldn't.
I can't get any of these to work. I assume because there are ["] in the command line I'm trying to execute and RUN needs ["] to execute.
lc = [c:\Program Files\HTML Compressor\ahc.exe "myHTMLfile.html"]   
     ** Note parameter is inside ["]
run &lc
run "&lc"
run (lc)
run ('"'+lc+'"')

lc2 = ["]+lc+["]
run &lc2
run (lc2)

lc2 = [']+lc+[']
run &lc2
run (lc2)

lc = [c:\Program Files\HTML Compressor\ahc.exe 'myHTMLfile.html']   
     ** Note using ['] instead of ["]
run (lc)
run "&lc"
maybe there is some other combination that will work.


>Hi Bill,
>
>Have you tried using a name expression rather than macro expansion?
>
>
run (lc)
>
>That appears to work to me.
>
>Cheers,
>
>Andrew
>
>>Hi Glenn,
>>
>>Finally got a simple one to run by doing:
>>lc = getfile()
>>run ["&lc"]
>>
>>Now I need to include a parameter in lc:
>>
>>lc = getfile()
>>------ option 1 -------
>>lc = lc + [ "] + lcParameter + ["]
>>run ["&lc"]     && doesn't work because there are ["]s in lc
>>run ['&lc']     && doesn't work either
>>
>>------ option 2 -------
>>lc = lc + [ '] + lcParameter + [']
>>run ["&lc"]     && doesn't work either
>>
>>Any idea how I can accomplish this?
>>
>>
>>
>>>Hi Bill,
>>>
>>>The run command itself requires the quoted string to pass the quotes to the command line therefore to execute this command try this:
>>>
>>>run ["c:\Set Time\settime.bat"]
>>>
>>>
>>>This will work every time.
>>>
>>>Glenn Domeracki
>>>
Bill Morris
Previous
Reply
Map
View

Click here to load this message in the networking platform