Jump to content

Recommended Posts

Posted

Can anybody tell me the special keys tested with ControlSend command of v.83?

sending {ENTER} key failed for me.

Below is the code tried

$Var="test"
ControlSend($ChildWindowTitle, $ChildWindowText,"Edit3",$Var & "{ENTER}",0)
Posted

Only Text for now as far as I know, but they are adding in new stuff every release. Stay tuned I guess. I keep testing my chr() as well each release. :whistle:

AutoIt3, the MACGYVER Pocket Knife for computers.

  • Administrators
Posted

The only one that doesn't work for me is ALT combos like !f. I had some code that almost got it to work (brought up a menu) but it failed when the window was not active so I removed it.

{ENTER} works fine here under XP though.

Edit: Just tested {ENTER} under 95 and it works here.


 

  • Administrators
Posted

This is the sort of code I've been testing:

If WinExists("Document - WordPad") Then
    WinActivate("Document - WordPad")
Else
    Run("write.exe")
EndIf

WinWaitActive("Document - WordPad")

Sleep(2000)
ControlSend("Document - WordPad", "", "RICHEDIT50W1", "1234{ENTER}{LEFT 2}{ASC 65}")


 

Posted (edited)

Sorry, I was just testing it out and home and this is the one machine I didn't update.

Every command works great for me now.

It was pretty funny since I had all the {} command in one file.

Anyhow My appologies, and I couldn't edit my post fast enough.

...edit CHR() work fine as well. and {enter} works on win2000 as well

Edited by scriptkitty

AutoIt3, the MACGYVER Pocket Knife for computers.

Posted

Most likely not the names, but the program you are doing it on. A lot of programs have layers, and controlsend doens't work well. Like IE and these edit boxes for instance.

Can you send control text?

AutoIt3, the MACGYVER Pocket Knife for computers.

  • Administrators
Posted

If they are edit controls does ControlSetText not work? ControlSend is a last resort after the ControlSetText function really.


 

Posted

ControlSetText works with CHR(13). Have not tried with {ENTER} for ControlSetText.

From AutoSpy, could see a control called "SS32D25EditHScroll1". On the screen, it seem to be a grid control. Send() works fine here. but unable to use ControlSend().

any idea?

Posted

for ControlSetText(), i need to press the ENTER key so that, application validates the input and fills up other related fields with corresponding values. If no enter key pressed, other fields won't be filled up.

Seems ControlsetText() does not support {ENTER} key for Edit boxes.

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...