blanks in directory name

Started by bmcnish, January 07, 2016, 02:51:01 PM

Previous topic - Next topic

bmcnish

I have a script that does DirExist("%destdir%") where the destdir ihas blanks in the name .  It always fails on this line.  How can I get it return a true value?

td

The DirExist function does not care where or not the input path contains blank characters.  Why are you using substitution and what do you mean by 'fail'?
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

snowsnowsnow

I would imagine that if the "destdir" variable contains newlines (I.e., CRLF) in it, the above statement would "fail" big time.

td

If by "fail big time" you mean the function returns zero, that is correct.
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade