evg64 Posted February 10, 2008 Share Posted February 10, 2008 I can`t understand how to use @DesktopCommonDir. I tried some variants: #include "@DesktopCommonDir\MyFile.au3" or #include "@DesktopCommonDir&\MyFile.au3" But all of them doesnt work. MyFile.au3 exists on my Desktop. Link to comment Share on other sites More sharing options...
xzaz Posted February 10, 2008 Share Posted February 10, 2008 #include <@Desktopdir&"filename.au3"> ? Small Color Picker v0.2 | Travian bot Link to comment Share on other sites More sharing options...
Roofel Posted February 10, 2008 Share Posted February 10, 2008 First of all:) @DesktopCommonDir is used to get to the Desktop:) Lets make it that you want the script to make a .ini file at the desktop, then you write IniWrite(@DesktopCommondir & "\Settings.ini", "Main","Data", "") When you execute the script it will make a Ini file with the name "Settings.ini" on the desktop. Check the Helpfile for Macro's and you will find what the different "@"-items is used for:) the @-macros arent used in "#include" just place the .au3 file as far as i know:) Hope it helped:) Never argue with an idiot, he will just bring you down to his own level and beat you with experience! :D Link to comment Share on other sites More sharing options...
Swift Posted February 10, 2008 Share Posted February 10, 2008 Its Better To Use @DesktopDir Then @DesktopCommonsDir I've had problems in the past using it...but if you want to write to a file? go ahead...and for #Include...you Dont use the macro @(blah) you just put #Include "File.au3" and it comes from where ever the script is..basically...@ScriptDir...hope this helps. Link to comment Share on other sites More sharing options...
evg64 Posted February 11, 2008 Author Share Posted February 11, 2008 But what if the script will be executed on another computer, where the is the same file on desktop? Just to write path like #include "path to desktop\MyFile.au3" won`t work, here must be used @DesktopCommonDir macro, but how exactly to use it? Link to comment Share on other sites More sharing options...
weaponx Posted February 11, 2008 Share Posted February 11, 2008 But what if the script will be executed on another computer, where the is the same file on desktop? Just to write path like#include "path to desktop\MyFile.au3"won`t work, here must be used @DesktopCommonDir macro, but how exactly to use it?You can't use variables in the include path... Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now