Sign in to follow this  
Followers 0
Xander

Can a compiled EXE call a AU3 script?

5 posts in this topic

As I get the hang of things here, I want to eventually get one master script that can do all the things I want.

The plan will be to have all my options for installing things like Spybot, Adaware, and so on, as well as allowing for adding a few .reg entries ....

Until I have things perfected, I want to know if I can prune down the master control script to simply call up the sub-scripts. This way, if anything goes wrong with one of them, the rest can continue on.

I know I can compile each separate sub-script into its own EXE but I'll be keeping these on a flash drive and want to keep things tight and clean.

I have looked at the Help file but either it's not there, or I'm missing it.

Share this post


Link to post
Share on other sites



Look at "Include". You can include your own au3 files. The most common one you would probably know would be #include <GUIConstants.au3>. In the file you include you can put all your functions etc in it.

Not sure what you meant by...

This way, if anything goes wrong with one of them, the rest can continue on.

If a function fails in an included script the whole program/sript running will get an error or w/e and exit.

[u]Old Projects:[/u]A3MORGB2Hex[u]Old Functions:[/u]_TimeAdd/_TimeSub_AddComma_BubbleSort _RippleSort "He who does not understand your silence will probably not understand your words." - Elbert Hubbard.

Share this post


Link to post
Share on other sites

Hi,

u want to make one spyware removal tool ?

If so have a look at www.hitmanpro.nl it's made in autoit an does what u want.

Andre


What about Windows without using AutoIt ?It would be the same as driving a car without an steering Wheel!

Share this post


Link to post
Share on other sites

You can call other script from an executable. You would need to have Autoit3.exe. to run the scripts.

Your compiled script would have something like:

RunWait(@ScriptDir & '\Autoit3.exe Script1.au3')

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

" If a function fails in an included script the whole program/sript running will get an error or w/e and exit."

Hmmm. Well, I'm doing pretty well so far. I guess I'll just have to be extra careful. Just hard to troubleshoot because, even if all works fine on my own system, it doesn't guarantee the same on another's.

Andre, I've looked at Hitman, but it's not as versatile as I want. I'll be doing things like changing the default settings, creating weekly tasks, running TeaTimer (spybot) if it's a Win98 system, and so on.

Eventually, I want to get to the point where I run it, it checks the OS and other variables, and offers pre-checked actions. Just a matter of changing those options if needed, and telling it to run them. (For that, I'll have to advance to the GUI).

MHz, just to reconfirm what was said earlier. If a run script as you cite has an error, it kills the operation of the whole thing, or just comes back with an error code?

Edited by Xander

Share this post


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
Sign in to follow this  
Followers 0