Jump to content

how to give $all to Var1, Var2


 Share

Recommended Posts

hello i want to give $all to varabuils like this.

$all = $var1&$var2&Var3

Did you mean

$all = $var1&$var2&$Var3

?

There is nothing wrong with that. SInce you say "give $all to varabuils" do you mean that you want all those variables to have the value that $all has? In which case you just need to have

$var1 = $all

$var2 = $all

etc

If you have a lot of variables then use an array

For $n = 0 to UBound($var) - 1

$var[$n] = $all

Next

Otherwise can you explain what the problem is? Ie what you want to do and what the problem is with what you have tried.

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

I think it's not difficult to misinterpret what you're asking for. Anyway, I'll try to clarify something else, just in case this is what you actually need.

Read an AutoIt statement like:

$MyVariable = 1 + 2

this way:

AutoIt will evaluate the right-hand expression (whatever is on the right of the = sign) which is here 1 + 2 and it will come up with the value 3.

Then it will assign (store) this computed vale to the variable designated by the left-hand part. Thus it will store 3 into $MyVariable.

Instead of the sign = it would have been much clearer to write it:

$MyVariable ← 1 + 2

For practical reasons, this notation didn't get used in most languages (due to limited character set).

Read the = (assignment operator) as "becomes".

So if you want to assign $all to three variables, make it like Martin showed you: three assignments in sequence.

In AutoIt, & is the string concatenation operator, so your statement is almost valid (missing a $), albeit not obviously what you want.

BTW, read the help file with more care.

Edited by jchd

This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.
Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe here
RegExp tutorial: enough to get started
PCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta.

SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.
SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.
An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.
SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)
A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!
SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt)

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