Jump to content

help - very hard one! don't know if autoit can do it.


 Share

Recommended Posts

is there an ability to alter a variable that when a script is running the second time it will not use the original value?

like:

$i=0
while 1
      select
            case $i=0
             do xyz
            case $i=1
             do xyz
     endselect
wend

; i need to start the next time the script runs with $i=1 and to stay that way.

another example, is where asking for a server address the first time the script runs, and for now on the user don't have to put it again.

any idea?

Link to comment
Share on other sites

is there an ability to alter a variable that when a script is running the second time it will not use the original value?

like:

$i=0
while 1
      select
            case $i=0
             do xyz
            case $i=1
             do xyz
     endselect
wend

; i need to start the next time the script runs with $i=1 and to stay that way.

another example, is where asking for a server address the first time the script runs, and for now on the user don't have to put it again.

any idea?

You just need to use an ini file. Look up IniRead and IniWrite.

Just set the Default value for a variable in your IniRead statement and then the first time the script runs it will use that value. When a new value is given you write it with IniWrite. Then the next time the script runs it will read the latest value.

The same sort of thing can be done with RegRead and RegWrite.

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
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...