lukeone Posted April 21, 2015 Share Posted April 21, 2015 Hi, I have the problem that an auto incremental integer from a for loop, got sent with pressed shift, since the special characters are those shift-binded at the actual value at the keyboard. So the number "5986" gets "%)(&". I tried different approaches like Send("{CAPSLOCK OFF}") before the int got sent. Im also casting the int to string with String() before sending it. Very strange is the fact, that the problem occurs just after passing the loop a few times with a correct sent int. Any idea? Thanks in advance and many greetings, Luke Link to comment Share on other sites More sharing options...
Danp2 Posted April 21, 2015 Share Posted April 21, 2015 Post some code that demonstrates the problem. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
lukeone Posted April 21, 2015 Author Share Posted April 21, 2015 (edited) expandcollapse popup$steps = 0 Run("app.exe") WinWaitActive("xxx") WinClose("xxx") WinSetState("xxx2","",@SW_MAXIMIZE) WinWaitActive("xxx2") Sleep(2) Send("!w") Sleep(1) While 1 Send("{HOME}") For $i = 0 To $steps Send("{DOWN}") Next Send("{ENTER}") WinWaitActive("[REGEXPTITLE:xxx3\s\W\D*]","") $title = WinGetTitle("[REGEXPTITLE:xxx3\s\W\D*]") WinSetState($title,"",@SW_MAXIMIZE) Send("{ALT}{a}") for $k = 1 To 5 Send("{DOWN}") Next Send("{ENTER}") WinActivate("xxx4") if WinWait("xxx4","",3) Then Send("{ENTER}") WinWait("xxx5","",3) Send("{CAPSLOCK OFF}") $stringified = String($steps) Send(StringLower($stringified)&StringReplace($title,"/"," "),1) Send("{ENTER}") WinWaitActive("[TITLE:xxx6; CLASS:#666]","") Send("{ENTER}") EndIf WinWait($title,"") WinClose($title) $steps = $steps + 1 WEnd Thats the whole script. Edited April 21, 2015 by lukeone Link to comment Share on other sites More sharing options...
Danp2 Posted April 21, 2015 Share Posted April 21, 2015 And the name of the program you are trying to automate? Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
lukeone Posted April 21, 2015 Author Share Posted April 21, 2015 Hi Danp2, I have to keep this discreet as you can see. I hope this is respected, because it concerns company internals and its legally required from me, so I'm sorry about that. However since I can't make the application public, it shouldn't be necessary or any help to the problem. Thanks and best regards, Luke Link to comment Share on other sites More sharing options...
Danp2 Posted April 21, 2015 Share Posted April 21, 2015 You are legally prevented from disclosing the name of the application? Sounds suspicious to me. FWIW, there are generally better ways to interact with most applications other than using the Send command. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
lukeone Posted April 21, 2015 Author Share Posted April 21, 2015 You are legally prevented from disclosing the name of the application? Sounds suspicious to me. That's right. I can't tell you more, but be reassured I'm not from the feds and its nothing illegal. FWIW, there are generally better ways to interact with most applications other than using the Send command. Thanks for the suggestion, but I still wonder how the Integer gets converted or SHIFT is pressed. Link to comment Share on other sites More sharing options...
Danp2 Posted April 21, 2015 Share Posted April 21, 2015 You may want to check out this FAQ. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 21, 2015 Moderators Share Posted April 21, 2015 lukeone,Take a look at this Wiki FAQ entry - it might help. but be reassured I'm not from the feds and its nothing illegalI am pretty sure the first of those was not what was being suggested - but the >Forum rules do explain what might be construed as "illegal" here.M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
lukeone Posted April 21, 2015 Author Share Posted April 21, 2015 (edited) You may want to check out this FAQ. Thanks I think this should help lukeone, Take a look at this Wiki FAQ entry - it might help. I am pretty sure the first of those was not what was being suggested - but the >Forum rules do explain what might be construed as "illegal" here. M23 Another thanks is flying out to you. I read the rules, its still legit My last try to make it clear: I'm not American and our laws are different. If I tell the wrong company internals public, they could sue me really bad. Thats my only concern. The application itself is completely company property (thats what the discreetness is all about), if you mind that. Thanks again and kind regards, Luke Edited April 21, 2015 by lukeone 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