Sign in to follow this  
Followers 0
itech

calling functions from a file

4 posts in this topic

Hi all, i am new to autoit. i will be doing a lot of programs that are similar in nature. so what i want to do is create a autoit file with all the common functions that i create and will be using in other scripts program.

so basically, in script1 i would like to call the function connect_to_internet which will be located in a separate file.

how can i do that.

Share this post


Link to post
Share on other sites



Make a custom include file.

Share this post


Link to post
Share on other sites

$Test = FileRead(@ScriptDir & "\test.txt") ; <--- put some AutoIt code in that file
Execute($Test)

I tested it with a MsgBox(0,"","") and it worked... Just a thought... :D

It will only work on single line scripts.


Broken link? PM me and I'll send you the file!

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