Re: file_exists and file name in quotes
- Posted by clk824 Jan 01, 2011
- 1068 views
I get value of environment variable which contains full path of executable file in quotes. In my case value is: "C:\Program Files\Notepad++\notepad++.exe"
My code:
sequence editor = getenv("EDITOR") if not file_exists(editor) then editor = getenv("WINDIR") & "\\notepad.exe" end if system_exec(editor)
I always get runned notepad. If i enter in console %editor%, proper editor runned and i think system_exec must work just the same.