walle Posted November 26, 2006 Posted November 26, 2006 Oki, this will be pretty hard to explain. My English isn't good at all I'm searching for a script that changes a line in my code every time I switch the scripts name. Example: I change the name on the .au3 file from hey too hey2. At the same time, a line in the code changed from hey to hey2. So it depends on the files name. Hope you understand //Walle
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 Oki, this will be pretty hard to explain. My English isn't good at all I'm searching for a script that changes a line in my code every time I switch the scripts name.Example: I change the name on the .au3 file from hey too hey2. At the same time, a line in the code changed from hey to hey2. So it depends on the files name. Hope you understand//WalleYou know about the macro's available like @ScriptName ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
walle Posted November 26, 2006 Author Posted November 26, 2006 You know about the macro's available like @ScriptName ?I'm 100% newbie, I will take a look at @ScriptName , but can't you explain more further?
/dev/null Posted November 26, 2006 Posted November 26, 2006 I'm 100% newbie, I will take a look at @ScriptName , but can't you explain more further? depends on the line that you want to change in your script. Post that line and we will be able to help you ...CheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
walle Posted November 26, 2006 Author Posted November 26, 2006 Thanks for the fast respone, well. My macro is very simple, just keystrokes at the moment. Played around with @ScriptName and didn't get any further. Tried: run ("notepad.exe") Send("@ScriptName") The named the .au3 file "Hey.au3".
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 run ("notepad.exe") sleep(5000) Send(@ScriptName) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
walle Posted November 26, 2006 Author Posted November 26, 2006 run ("notepad.exe")sleep(5000)Send(@ScriptName)Thanks!, just found it out myself too
/dev/null Posted November 26, 2006 Posted November 26, 2006 Thanks for the fast respone, well. My macro is very simple, just keystrokes at the moment. Played around with @ScriptName and didn't get any further. Tried: run ("notepad.exe") Send("@ScriptName") The named the .au3 file "Hey.au3". Not quite. Try this: $name = @Scriptname run ("notepad.exe") WinActivate("Untitled") Send("The name of the script is: " & $name) Cheers Kurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 Not quite. Try this: $name = @Scriptname run ("notepad.exe") WinActivate("Untitled") Send("The name of the script is: " & $name) Cheers KurtGetting slow Gurt !!! SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
/dev/null Posted November 26, 2006 Posted November 26, 2006 Getting slow Gurt !!! Yeah, dammit.... But who is Gurt? __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 Yeah, dammit.... But who is Gurt?Sorry .. getting confused Gary-Kurt = Gurt SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
walle Posted November 26, 2006 Author Posted November 26, 2006 (edited) Well, Can I get rid of .au3?, Using it in to searsh for a file and it can't find it with the .au3 in the end Once again, thx for the help Edited November 26, 2006 by walle
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 Well, Can I get rid of .au3?, Using it in to searsh for a file and it can't find it with the .au3 in the end Any of these:StringTrimRight()StringReplace()StringLeft()I am sure you figure it out .. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
/dev/null Posted November 26, 2006 Posted November 26, 2006 Sorry .. getting confused Gary-Kurt = Gurt Oh, yes... forgot that I'm GF. You're absolutely right....ByeGurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
/dev/null Posted November 26, 2006 Posted November 26, 2006 Well, Can I get rid of .au3?, Using it in to searsh for a file and it can't find it with the .au3 in the end Once again, thx for the help $name = StringTrimRight(@Scriptname,4) Bye Gary-Kurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
Moderators SmOke_N Posted November 26, 2006 Moderators Posted November 26, 2006 Well since we are all having fun... $File = @HomeDrive & '\ScriptFun.txt' FileClose(FileOpen($File, 2)) FileWrite($File, @ScriptName) Run('"' & @SystemDir & '\notepad.exe" "' & $File & '"') WinWait("ScriptFun.txt - Notepad") FileDelete($File) 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.
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 ByeGary-KurtWhat about Kary ? sounds sexy SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
walle Posted November 26, 2006 Author Posted November 26, 2006 Heheh, Didn't get the string thing to work, so, made it in my on way end (@scriptname) Send("{backspace}") Send("{backspace}") Send("{backspace}") Send("{backspace}") Hehe, I will test smokes script right away
Valik Posted November 26, 2006 Posted November 26, 2006 Wait a minute now, that's getting too close to my name. JdeB, make him change his name back to /dev/null........pls. Or he could just change it for him.
Developers Jos Posted November 26, 2006 Developers Posted November 26, 2006 Heheh, Didn't get the string thing to work, so, made it in my on way Send (@scriptname) Send("{backspace}") Send("{backspace}") Send("{backspace}") Send("{backspace}") Hehe, I will test smokes script right away Send (StringTrimRight(@scriptname,4)) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
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