antineff Posted January 15, 2017 Share Posted January 15, 2017 Hi all, As I'm a complete beginner to AutoIt I really hope I don't bother you with a maybe simple question that is already discussed in this forum, but I could not find a matching thread. Trying to follow the beginners tutorial I found that early lesson where I have to use the Send command to send some text to an opened notepad window. Here I encountered a strange behaviour of the @CRLF macro: Used after the second string it only did a CR and not a CR + a LF as it did in the first concatenation. I found that the sentence in the second strin ended with an exclamation mark (!). When I substituted it by a dot (.) everything worked fine. Then I placed an exclamation mark in the middle of the string and the script started to do wild things and writing into my opened script file instead of the notepad window. After that I tried to put all kind of special characters into a string and found that some more are at least not displayed (like ^°+~ and maybe more). How can I use those characters within strings? It doesn't make any difference if I use single or double quotes to define the string. Link to comment Share on other sites More sharing options...
kaisies Posted January 16, 2017 Share Posted January 16, 2017 Welcome! You'll have to post your code (or a small snippet that can be run) in order to get help here. Otherwise it's just guessing Link to comment Share on other sites More sharing options...
Subz Posted January 16, 2017 Share Posted January 16, 2017 (edited) If you look at the Send Function in Autoit Help, you'll notice that ! = ^ and # are special characters and so require '{!}' to send those keys. Edited January 16, 2017 by Subz Link to comment Share on other sites More sharing options...
antineff Posted January 16, 2017 Author Share Posted January 16, 2017 Sometimes you can't see the forest for the trees! I looked up everything, but not the helpfile for the Send command!!! Thank you very much, Subz! That solves my problem perfectly! 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