crest Posted October 27, 2006 Share Posted October 27, 2006 (edited) Hey guys,im once again in need of your help.global $var = "{F3}" send("{"$var"}")i wanted to store a Keyboard-button in the variable $var, so that its easier to use/change the send()-function whenever i want this button ( F3 ) to be pressed in the active window.Yet im getting an Error-message right at this point.Errormessage:send("{"$var"}")send(^ ERRORerror: error in expressionAnd since im rather new to autoit and programming i dont know the right syntax to make this work Hope, someone can help me Edited October 27, 2006 by crest Link to comment Share on other sites More sharing options...
Valuater Posted October 27, 2006 Share Posted October 27, 2006 (edited) send($var) May not do what you think, i have never tried it... but it shouldn't error-out 8) Edited October 27, 2006 by Valuater Link to comment Share on other sites More sharing options...
PaulIA Posted October 27, 2006 Share Posted October 27, 2006 (edited) global $var = "{F3}" send($var)oÝ÷ ÚÚºÚ"µÍÛØ[ ÌÍÝH ][ÝÑÉ][ÝÂÙ[ ][ÝÞÉ][ÝÈ [È ÌÍÝ [È ][ÝßI][ÝÊoÝ÷ ÚÚºÚ"µÍÛØ[ ÌÍÝHH ][ÝÑ][ÝÂÛØ[ ÌÍÝH ][ÝÌÉ][ÝÂÙ[ ][ÝÞÉ][ÝÈ [È ÌÍÝH [È ÌÍÝ [È ][ÝßI][ÝÊor ... Edited October 27, 2006 by PaulIA Auto3Lib: A library of over 1200 functions for AutoIt Link to comment Share on other sites More sharing options...
theguy0000 Posted October 27, 2006 Share Posted October 27, 2006 (edited) well, first, send("{"$var"}") if $var is {F3} then you end up sending {{F3}}, which I'm assuming you don't want. remove the brackets from $var = "{F3}" Second, you need to seperate string and variables with the & symbol. send("{"$var"}") should be send("{" & $var & "}") you're welcome Edited October 27, 2006 by theguy0000 The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Link to comment Share on other sites More sharing options...
crest Posted October 27, 2006 Author Share Posted October 27, 2006 Thanks to all of you its working now )) 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