Jump to content

BrainStorming - Dynamic Script

Recommended Posts

Is it possible to build a dynamic script in Autoit .... in the sense that:

Lets say I have a few products. When the script runs this is what I want to happen.

I want the script to evaluate which product is running, then accesses a .INI file (The . INI file will hold the product and the list of processes/functions that I want to run based on that product name), find the product name and the list of processes and then run those processes for that product.

Is this wacky? Can this be done with Autoit?

Link to comment
Share on other sites

I am sure that this is possible, I currently have some scripts that change what they are doing depending on various system variables plus what the user enters. Reading from an INI file depending on how many process/tasks that you want to run may not be the answer, but you could setup a file using a similar or unique format. (As you are making the script, your not limited to any standards, just need to remember what you did so you can change it as needed.)

what I did was write a flow diagram on what needs to run depending on what conditions, and then used both if and case statements to determine what needed to happen.

Kerros===============================================================How to learn scripting: Figure out enough to be dangerous, then ask for assistance.

Link to comment
Share on other sites

So I found the easiest way to do this is to have a whole bunch of cases of stuff you want to do. Also have an INI file with with a section for each product and then within each section the the numbers or strings associated with each case you want to execute. Grab it from INI, place in array and for each element in the array run through the list of cases and execute. JUST IN CASE SOMEONE WANTED TO KNOW.

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

  • Recently Browsing   0 members

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