Jump to content

Script acts differently when compiled - exits While loop

Recommended Posts

So I have a very simple script that works fine when I run it with "Go" from the Tools menu of SciTE, but does not when I compile and run it as an executable.


While 1
    If FileExists("C:\Folder\File.exe") Then

When run as a "Go" it does what you would expect, and runs the File_m00.exe, and then continues to loop, looking for a new File.exe to appear.


When I compile, it loops dutifully until it encounters the File.exe, does the rename(move) and then runs the File_m00.exe. However, the program then exits. Is there something I am missing with the Run command in a compiled script that differs from running it uncompiled?

Link to post
Share on other sites
  • Developers

The shown script will not exit after the run just like that.
Do you get any error?
What does File_m00.exe actually do? does it kill some processes?
What is the name of the compiled script?


SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
Live for the present,
Dream of the future,
Learn from the past.

Link to post
Share on other sites

Jos, thanks for the quick reply. I agree that it should not exit after the run, so I did some more digging/testing.

This was made for my work PC, and I was getting that unexpected result on that machine.

I then tested on my home PC, and do not get the same results. It works as expected on home PC.

I will guess that my work PC, with all the junk software that IT forces on us, notices that the script calls another executable, and then decides it is dangerous. No errors, no alerts, just kills the process.

Kind of surprising that it doesn't kill the AutoIt3.exe process when running the uncompiled script.


This is not an AutoIt issue, so my apologies for making a new topic, but I was totally stumped.



Edited by m00
Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...