WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: markgolay on June 20, 2016, 05:39:47 AM

Title: Fileexist not working when debug(F5)
Post by: markgolay on June 20, 2016, 05:39:47 AM
Upgraded to windows 10 recently , an old Program works when compiled, however when I run in debug it fails on fileexist == @FALSE ,but if I compile it fileexist == @TRUE, any ideas how crazy
Title: Re: Fileexist not working when debug(F5)
Post by: td on June 20, 2016, 06:49:19 AM
Are you referring to the output from the WinBatch function FileExit?  If so, are you passing the full path,including the drive and file system root, to FileExist or are you passing a relative or partial path?  If it is the later, WinBatch Studio and your compiled scripts will often have a different working directories and fill in the missing path information differently because of this.   

In any event, there are no known problems with FileExist on Windows 10 and your problem likely has nothing to do with the version of the operating system unless you upgraded from an early version of XP.
Title: Re: Fileexist not working when debug(F5)
Post by: markgolay on June 30, 2016, 02:08:02 PM
Have it working , I had as Mapped drive letter which made it fail , but worked on windows 7 , I have now just used full path & not using map drive any more
Title: Re: Fileexist not working when debug(F5)
Post by: td on June 30, 2016, 03:56:31 PM
This Tech Database article does a good job of explaining mapped drives in a UAC environment.   Note that the Windows 8 paragraph at the bottom of the article also applies to Windows 10.

http://techsupt.winbatch.com/webcgi/webbatch.exe?techsupt/nftechsupt.web+WinBatch/UAC+Mapped~Drives~Issue~with~UAC.txt (http://techsupt.winbatch.com/webcgi/webbatch.exe?techsupt/nftechsupt.web+WinBatch/UAC+Mapped~Drives~Issue~with~UAC.txt)