Jump to content

"Case" statement like in C++?


Recommended Posts

I know that in C++ there is a useful statement called "Case" which is used to stop programmers from having to write:

if
    then
         if
              then
              else
          endif
    else
endif

I am writing a program that looks at a variable and does different things based on what the variable is, is there a quick way to do this in AutoIt without using endless if statements?

Help would be much appreciated,

AlterCtrlEgo,

http://www.alphahacka.com/ forum admin

Link to comment
Share on other sites

Look up

Switch .. Case..Endswitch

Select..CAse..EndSelect

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

  • Moderators

Sorry for being such a n00b, but I cannot find any information on this, are there any examples you can point me towards or any good sites?

Thanks,

AlterCtrlEgo

http://www.autoitscript.com/autoit3/docs/i...conditional.htm

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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...