What is longest possible NT PATH statement?

What is the longest PATH statement possible in Windows NT? When you get the Path env var it seems to always be with short file names.  So at what point do the directory names in the PATH statement get ignored?  It seems to be 512 sometimes and maybe more on other NT boxes, what is the rule? NT workstation differs from server? Details, please.
edgaregnerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

edgaregnerAuthor Commented:
Adjusted points to 75
0
edgaregnerAuthor Commented:
MAX_PATH is not the answer. MAX_PATH refers to the maximum size of one name of a file - directory name plus file name.
0
allymCommented:
I set my path to C:\1234567890;c:\1234567890........ and finished with c:\1
I filleds the command prompt buffer with 2K worth of path, with only one valid directory at the end, and NT workstation 4.0 SP4 picked up the very last bit of the path.  

So I reckon that the answer is at least 2046 bytes (the exact number of bytes I set).

The control panel applet only allowed me to put 305 bytes in the user PATH.  I didn't disk around with the system PATH here.  You can if you want to.

Of course, this is only the answer for command prompts; maybe you can set the path bigger for applications.  If you have a particular need, then test it as I did.  

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
edgaregnerAuthor Commented:
This addresses the PATH statement in a DOS virtual machine and it addresses the PATH statement being set thru the Control Panel Applet.  I will also look at setting the PATH statement programmatically.
0
edgaregnerAuthor Commented:
I am beginning to believe that there is no set maximum PATH statement.  There is a maximum environment of which the PATH statement is a part.  The article in the URL below does not explicitly state this but does lead me to this conclusion.

http://support.microsoft.com/support/kb/articles/q223/2/75.asp
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows OS

From novice to tech pro — start learning today.