Jump to content

FileChangeDir cause exe file to run endless times


h711
 Share

Recommended Posts

I need to launch my script from target program location. So I do the following:

FileChangeDir("E:\")
Run("Install.exe")

This code works fine if you run it from .au3 file, but once you compiled it to exe and click on it, it will repeatedly launch itself endless times.

Run("E:\Install.exe")
works fine for both .au3 and .exe. So I assume
FileChangeDir("E:\")
is the part that caused the trouble.

Any ideas? Thanks!

Link to comment
Share on other sites

I need to launch my script from target program location. So I do the following:

FileChangeDir("E:\")
Run("Install.exe")

This code works fine if you run it from .au3 file, but once you compiled it to exe and click on it, it will repeatedly launch itself endless times.

Run("E:\Install.exe")
works fine for both .au3 and .exe. So I assume
FileChangeDir("E:\")
is the part that caused the trouble.

Any ideas? Thanks!

maybe theres a file in E that is called install.exe and that runs install.exe and it goes on in a loop?? OR MAYBE ITS BECAUSE FILECHANGEDIR DOES NOT MAKE THE SCRIPT LOOK FOR INSTALL.EXE IN DRIVE E:\ YOU NEED TO MAKE IT RUN("E:\INSTALL.EXE") AND THAT SHOULD WORK! Edited by LimeSeed
global $warming = true
Link to comment
Share on other sites

Ok, I found a way out.

FileChangeDir("E:")
Run("\Install.exe")

This seems to work for both .au3 and .exe. I guess it is the "\" been handled differently for .au3 and .exe.

No, that's not it.

You compiled your script to Install.exe and that caused it to run it self endlessly

Edited by trancexx

♡♡♡

.

eMyvnE

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...