Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Set Path to...is there a limit or something??
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00313968
Message ID:
00314093
Views:
38
>Is it the actual SET PATH command that can't handle it? Can you do something like
>
>SET PATH to blah\blah, blah\blah
>Set Path to &AllTrim(set('path'))) + ',' + moreblah\moreblah
>
>or something like that....don't think that I've got syntax correct there...but you get my idea....
>???????

Victor,

I think it's probably just the overall length of the string. The path statement is part of the environment, and, to hazard a SWAG, probably has some limitations set on it. In this case, 1K. Anyway, I created and tested this using the following (quite a few times < g >)from the command window
lcpath = SET('PATH')
* Get a filename
lcfile = GETFILE('*')
* Strip the path
lcfilename = JUSTFNAME(lcfile)
* Test to make sure that it can't be seen
? FILE(lcfilename)
* Get the file's path
lcfilepath = JUSTPATH(lcfile)
* Add it to the path statement
lcpath = lcpath + ";" + lcfilepath
* Set the new path
SET PATH TO (lcpath)
* Re-check to make sure the file is now seen
? FILE(lcfilename)
* Check the length
? LEN(lcpath)
This worked until the length exceeded 1,023 characters so my gut reaction is that it's a limitation in the environment space rather than anything else.
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform