Sign in to follow this  
Followers 0
VenomIT

Varables

6 posts in this topic

Hi ti all i have got most of the varables that autoit use.

Example

Now can some 1 please tell me whats the varable for "All Users" user documents and settings

?

5 - Macro_Varubales.rtf

Share this post


Link to post
Share on other sites



Search in helpfile for "Macro Reference - Directory".

BR,

UEZ


Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯  ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ

Share this post


Link to post
Share on other sites

So you want something like %ALLUSERSPROFILE% that the OS may offer? I do not see a macro for that one.

To know available Environmental Variables for your OS, then just type Set and press Enter at a command prompt to display all available Environmental Variables. To use an Environmental Variable in an AutoIt script, you can use EnvGet() to evaluate the string representation of the Environmental Variable name and get the value.

Example:

Global Const $ALLUSERSPROFILE = EnvGet('ALLUSERSPROFILE')
MsgBox(0x40000, 'ALLUSERSPROFILE', $ALLUSERSPROFILE)

Share this post


Link to post
Share on other sites

So you want something like %ALLUSERSPROFILE% that the OS may offer? I do not see a macro for that one.

Yet another way to do it:
; Default setting
Opt("ExpandEnvStrings", 0)
ConsoleWrite("All Users dir = %ALLUSERSPROFILE%" & @LF)

; How to get the environment variable with the default setting
ConsoleWrite("All Users dir = " & EnvGet("ALLUSERSPROFILE") & @LF & @LF)

; Changed setting
Opt("ExpandEnvStrings", 1)
ConsoleWrite("All Users dir = %ALLUSERSPROFILE%" & @LF)

:mellow:


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

Thanx for the Help :-)

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