Jump to content

ControlSend text to a textboox problem


Recommended Posts

Hello, i am very beginner in Autoit and i have a simple problem.

I created a script that use "ControlSend" function but i have a problem with the program were i need to automaticaly type text.

$result = _ImageSearchArea("2s.bmp",1,960,200,1050,255,$x1,$y1,110)
if $result=1 Then
    ControlSend("PokerStove - [PStove1]","","[CLASS:Edit; INSTANCE:2]","2s")

EndIf


$result = _ImageSearchArea("3s.bmp",1,960,200,1050,255,$x1,$y1,110)
if $result=1 Then
    ControlSend("PokerStove - [PStove1]","","[CLASS:Edit; INSTANCE:2]","3s")

EndIf

When _ImageSearchArea founds .bmp image then i need the name of that image to be typed in a textbox from a software called PokerStove.

All things are working right, the only problem is that after the script send the keys to the textbox, the software (pokerstove) dont want to work. :(

But the interesting fact is that if i manually input the EXACTLY same text (key stroke) in the PokerStove, then when i hit the evaluate button the software works.

I tried to add Opt('SendKeyDelay', 250); but the result is the same, even if the typing is more slowly.

I dont know what to do, maybe i need to put something at the end of code.

Thank you.

Pokerstove software: http://www.4shared.com/file/UYY6hrGG/PokerStove_124.html

and my script is made only from this kind of text:

$result = _ImageSearchArea("3s.bmp",1,960,200,1050,255,$x1,$y1,110)
if $result=1 Then
    ControlSend("PokerStove - [PStove1]","","[CLASS:Edit; INSTANCE:2]","3s")

EndIf
Edited by rony2006
Link to comment
Share on other sites

  • Moderators

rony2006,

It looks ot me as if you are trying to identify cards from within a poker game and then entering their value into Pokerstove to assess the odds. Please read the Forum rules (there is also a link at bottom right of each page) and make sure you follow them in future. Thread locked. :naughty:

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png 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 columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...