OT: How does Windows handle spaces in program names?

Bob Sneidar bobs at twft.com
Mon May 23 19:15:18 EDT 2011


Aye. It's the ole Readability vs. Compactness conundrum. 

Bob


On May 23, 2011, at 3:27 PM, Roger Eller wrote:

> or... to keep it as a one liner...
> 
> put quote & "C:\Documents and Settings\myprofile\Desktop\My App Name.exe" &
> quote into theFilePath
> 
> ˜Roger
> 
> 
> On Mon, May 23, 2011 at 6:19 PM, Bob Sneidar <bobs at twft.com> wrote:
> 
>> I may or may not have responded to this, but you cannot simply enclose the
>> program name in quotes for the argument to the shell command, because
>> Livecode will simply interpret whatever is between the quotes and send that.
>> 
>> Instead, put the path to the app or file you want to work with into a
>> variable, say:
>> 
>> put "C:\Documents and Settings\myprofile\Desktop\My App Name.exe" into
>> theFilePath
>> 
>> then insert the quotes so that the quotes are actually a part of the
>> contents of the variable like so:
>> put quote before theFilePath
>> put quote after theFilePath
>> 
>> Now shell it out:
>> put shell(attrib && theFilePath && "+R") into myResult -- assuming you are
>> trying to get the attribute
>> 
>> Does this not work for you?
>> 
>> Bob
>> 
>> 
>> On May 23, 2011, at 2:51 PM, Warren Samples wrote:
>> 
>>> On Monday, May 23, 2011 04:27:38 PM Graham Samuel wrote:
>>>> I tried "My spacious program.exe" since I couldn't see how to introduce
>> a
>>>> further level of quotes.
>>> 
>>> 
>>> Maybe it just won't work, but did you try to use the single quote char '
>> ? I don't know if this is valid under
>>> Windows, but " and ' are interchangeable in Bash and Livecode lets you
>> use it to quote filepaths etc. within a
>>> quoted string, at least here under Linux.
>>> 
>>> Good Luck,
>>> 
>>> Warren
>>> 
>>> _______________________________________________
>>> use-livecode mailing list
>>> use-livecode at lists.runrev.com
>>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
>> 
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list