Re: [NRN] Problem with Options:PerlExe in ini file
- Hi Sheri,
S> How can I properly update Options:PerlExe before a ^!RunPerl is
S> executed. I was planning to bypass the ^!RunPerl if the ^$GetValue$
S> in Options:PerlExe doesn't exist (based on ^!IfFileExist).
I'm not quite sure what you are trying to do here, but ^$GetPerlExe$
will return the location of your perl.exe.
example (from my PerlDE clip library, an older version of which is at
the NoteTab site):
^!Shell "^$GetLibraryPath$launch.bat" "^$GetPerlExe$ ^$GetShort("^**")$"
So for what it seems you want to do, you could check the value of
^$GetPerlExe$ and if it's empty, bypass that part of your script that
I've copied this to the CLIPS list, so any conversation can continue
there (this list is for discussions on the Next Release)
- Hi Sheri,
S> It would be nice if the special purpose function could actually
S> locate Perl.exe when its on the path, without requiring the user to
S> browse to it. However, since this is usually only a one time setup
S> maybe it doesn't warrant the effort.
I wasn't aware that ^!GetPerlexe^ prompted for input, I thought it
just returned a blank value if there was no Perl.
I suppose your only choice then is to read the .INI file - copy the
contents of it to a variable, then test that variable with a regexp to
determine if there is something other than a "\n" next to the
"PerlExe=" ("PerlExe=\n" will be true if no perl, "PerlExe=.+\n" will
be true if there is a perl.)