Jump to content
Sign in to follow this  
DavidOLW

Combobox Set and Get Selection

Recommended Posts

DavidOLW

Trying to get the selection and also set the selection of a combo box in an external program. Using Autoit Info tool it shows the top as a combobox and the dropdown part as a list box giving the following details:-

Class: TspSkinComboBox

Instance: 5

ClassnameNN: TspSkinComboBox5

Name:

Advanced Mode: [CLASS:TspSkinComboBox; INSTANCE:5]

ID: 16909400

Text:

Position: 456, 133

Size: 160, 20

ControlClick Coords: 86, 9

Style: 0x56010000

ExStyle: 0x00010000

Handle: 0x01020458

Class: TspListBox

Instance: 1

ClassnameNN: TspListBox5

Name:

Advanced Mode: [CLASS:TspListBox; Instance 1]

ID: 766980

Text:

Position: 3, 3

Size: 138, 144

ControlClick Coords: 99, 45

Style: 0x54210151

ExStyle: 0x00000000

Handle: 0x0075086E

I have manged to get handles and ID via code of the above using WinGetHandle and DLLCall.

I have tried using GetCurrentSelection but it only returns "0" and when using SetCurrentSelection does not work.

FindString does not work.

Code below:

;ControlCommand("Jier Pro", "", 16909400, "SetCurrentSelection", "8")

;$index = ControlCommand("Jier Pro", "", 16909400, "GetCurrentSelection", 1)     
;MsgBox(0, "Text read was:", $index)

;$stext = ControlCommand("Jier Pro", "", 16909400, "FindString", "Number 1")     
;MsgBox(0, "Text read was:", $stext)

I have tried these on the Top combobox and list box below.

Any Idea's how to get information of items in the list or which is selected.

David

Share this post


Link to post
Share on other sites

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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.