Script reports different results compiled vs uncompiled.

Started by morenos1, February 19, 2014, 01:04:18 PM

Previous topic - Next topic

morenos1

I am working with this script which checks to see if a specific process is running.
I only know the first 3 characters of the process name (mct*.exe).

The script will be in a loop until the process is found and it will extract the whole process name (mct######).

If I run the script before I compile it, it works like it is supposed to (see DEBUG_uncompiled.TXT). It waits in the loop until the process shows up.

As soon as I compile the script, it never stays in the loop. It finds something and it ends (see WBDEBUG_compiled.TXT).

Why different results?

td

The usual cause is that your compiled script is finding itself because you have the partial name you are looking for as part of the compiled script's name.
"No one who sees a peregrine falcon fly can ever forget the beauty and thrill of that flight."
  - Dr. Tom Cade

morenos1

That makes a lot of sense!

Fresh eyes ....

Thank You.....