Jump to content

Beginner - Combobox display an item, how to


sqa
 Share

Recommended Posts

Hi, just started with AutoIT and stupedly cannot understand a very simple (pretty sure) thing.

How to display in a comboBox an existing string.

For example AutoIT Info says:

Name: ComboBox1

ID: 197566

isplayed string: 111

need to change it to the following one: 222

Thanks

Link to comment
Share on other sites

Hello sqa,

First, Welcome to the AutoIt Forums!

I'm not sure I have comprehended your question very well, however it sounds as if your looking for a way to change the data inside your combo box. If so:

GUICtrlSetData($controlID, $DataString, $newSelection)

*Note that if the first Char in $DataString is a pipe '|', then $DataString will replace the old values inside your combo, otherwise it will add the new values to the end.

However, If you mean to automate another application, and wish to change the selection in a combo box control inside the target application then you will want to use function:

ControlCommand( 'Title', 'Text', 'ControlID', "SelectString", 'string')

Realm

My Contributions: Unix Timestamp: Calculate Unix time, or seconds since Epoch, accounting for your local timezone and daylight savings time. RegEdit Jumper: A Small & Simple interface based on Yashied's Reg Jumper Function, for searching Hives in your registry. 

Link to comment
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
 Share

  • Recently Browsing   0 members

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