| View previous topic :: View next topic |
| Author |
Message |
imapow
Joined: 13 Mar 2008 Posts: 162 Location: Trøndelag, Norway
|
Posted: Wed May 14, 2008 7:08 am Post subject: something like a system32 folder for ahk |
|
|
one of the forst program coding i lernd war CMD batsh programing. some thing i found wery neet with cmd was the system32 folder. put any program, script ore function in the system32 folder and it becoms a code in cmd. is there eny sutsh folder in ahk?? _________________ -._.-¨¯¨-._.-IM@PΩW-._.-¨¯¨-._.- |
|
| Back to top |
|
 |
n-l-i-d Guest
|
Posted: Wed May 14, 2008 9:42 am Post subject: |
|
|
This is related to the Windows PATH variable. Windows itself has global variables too, they are also called environment variables (shortened by me to: env-vars).
You can find them "by hand" (Control Panels -> System -> Advanced system settings)
You can get them on the command line in a DOS box (setting them is more difficult)
You can get/set them directly in AutoHotkey with EnvGet/EnvSet.
AutoHotkey has most env-vars already built-in, prefixed with A_ (like: A_WinDir, A_ProgramFiles, etcet. You can compare them with the Wikipedia list).
The PATH env-var is a semi-colon delimited list of full paths to the directories in which executables look for dependencies. So, you can set your own "system32" directory, by adding it to the PATH env-var.
Changing system env-vars requires admin rights. User env-vars can be changed however. No restart required, but any programs that are already running will need to be relaunched for them to recognize the change.
To make it permanent, you can use Windows (Control Panel), if you want to automate it you'd might have to edit some file (autoexec.bat/config.sys, autoexec.nt/config.nt) depending on your system and/or the registry, and possibly restart.
HTH |
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 2558 Location: Australia, Qld
|
Posted: Wed May 14, 2008 9:59 am Post subject: |
|
|
Use Run.
| Run wrote: | If Target is a local file and no path was specified with it, A_WorkingDir will be searched first. If no matching file is found there, the system will search for and launch the file if it is integrated ("known"), e.g. by being contained in one of the PATH folders.
|
|
|
| Back to top |
|
 |
imapow
Joined: 13 Mar 2008 Posts: 162 Location: Trøndelag, Norway
|
Posted: Wed May 14, 2008 1:46 pm Post subject: |
|
|
k. thanks _________________ -._.-¨¯¨-._.-IM@PΩW-._.-¨¯¨-._.- |
|
| Back to top |
|
 |
|