Sign in to follow this  
Followers 0
Scoots

Selecting a value from a ComboBox

3 posts in this topic

#1 ·  Posted (edited)

I've been perusing these forums looking for an answer, but I haven't had much luck. Basically what I am trying to do is to populate combo boxes on a webpage based on input on a GUI that I created. I am not having too much trouble with it for normal entries, but anything with a special character in front is making things hard. I am not able to post the HTML source directly, but a sample would be this entry in the combobox:

<OPTION value="http://www.perl.com">   ·HELLO!

<OPTION value="http://www.perl.com"> &# 160; &# 160; &# 160; &# 183; HELLO!

The function I am using for non-weird character is this

Func FillCombo($oBox, $text)
    WinActive("IssueEntry - Windows Internet Explorer")
    _IEAction($oBox, "focus")
    Send($text)
EndFunc

where $oBox is the combobox that I want to update, and $text is the value that I am trying to find in the list. There might be a better way to send the information directly to the combo box, but simulating typing it is the best option I have found so far. Any help would be much appreciated!

Edit: Added spaces in the original HTML line to show the special character codes.

Edited by Scoots

Share this post


Link to post
Share on other sites



#3 ·  Posted (edited)

Thank you for your help. It turns out my problem is I was passing the wrong ASCII code when I was parsing the whole HTML file, so it ended up searching for the wrong value in the combo box. /sigh, that one's on me.

Edited by Scoots

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  
Followers 0