VelvetElvis Posted February 8, 2012 Share Posted February 8, 2012 I have an app that erases existing reports, then saves the updated reports by populating the "Save As" box with a variable, using Send()Ran into a problem this morning, where the text entered in the "Save As" dialog was missing a "#" in the filename. In other words, the Send() function wasn't sending my filename variable properly to the "Save As" box.In looking at the help file, I see that there are several characters that don't get literally sent (#, !, +, etc.)How can I deal with these characters, which can't be previously anticipated, as the filenames will change from time to time.If the only solution involves a regular expression, can someone give me a bit of help in that regard? Link to comment Share on other sites More sharing options...
Country73 Posted February 8, 2012 Share Posted February 8, 2012 May try using the ASCII Character code for # Chr(35) jvanegmond 1 If you try to fail and succeed which have you done?AutoIt Forum Search Link to comment Share on other sites More sharing options...
AdamUL Posted February 8, 2012 Share Posted February 8, 2012 (edited) Use the 1 flag for Send, to send raw keys, or enclosed special keys in braces {}. Look at some examples below.Send("#test#", 1) ;Sent raw Send("{#}test{#}") ;Using braces.Since you cannot anticipate what the file name will be, I would use the 1 flag.Adam Edited February 8, 2012 by AdamUL Link to comment Share on other sites More sharing options...
VelvetElvis Posted February 8, 2012 Author Share Posted February 8, 2012 Use the 1 flag for Send, to send raw text, or enclosed special keys in braces {}. Look at some examples below. Send("#test#", 1) ;Sent raw Send("{#}test{#}") ;Using braces. Since you cannot anticipate what the file name will be, I would use the 1 flag. Adam Thank you so much. I don't know how I ever missed that. Link to comment Share on other sites More sharing options...
AdamUL Posted February 8, 2012 Share Posted February 8, 2012 Glad, I could help. Adam 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