Right now if you don't remember that there are multiple versions of command.com to use with Run Program, then you end up with a problem when the script is run in a different environment.
Even if you do plan ahead for multiple environments, you need to make different IF statements. It would be much easier to use a system variable in the command line.
Example:
Win 9X environment
Win NT environmentRun Program>command.com /c find "mystring" c:\folder\myfile.txt > found.txt
Both environments, simplified:Run Program>cmd /c find "mystring" c:\folder\myfile.txt > found.txt
When doing for multiple environments, this techinque may be done multiple times, every time a Run Program uses a command line command.MidStr>OS_VER,1,2,Version
If>%Version%95,NT
Label>9x
Run Program>command.com /c find "mystring" c:\folder\myfile.txt > found.txt
Goto>More
Label>NT
Run Program>cmd /c find "mystring" c:\folder\myfile.txt > found.txt
Label>More
With a variable for the interpreter, like OS_COMMAND, we could do something like:
and use this in all environments.Run Program>%OS_COMMAND% /c find "mystring" c:\folder\myfile.txt > found.txt
This approach would also provide for upward growth. Example: If moving from WIN9X to XP, scripts need to be modified now. This approach would allow transport of scripts to newer OS without modifications.