Solved

Select a combobox item

Posted on 2011-03-15
10
708 Views
Last Modified: 2013-12-20
I have the following code but don't know the correct command to make a selection from a combobox on a website using internetexplorer object. The control name is "widgets" and you can select only one from a dropdowm menu of... widget1, widget2, widget3

Set ie = CreateObject("InternetExplorer.Application")
ie.Visible = True

ie.navigate "http://www.samplesite.com"
Do While ie.busy
Loop

ie.Document.all("widgets") = "widget1"
0
Comment
Question by:toecutter777
  • 4
  • 2
10 Comments
 
LVL 30

Accepted Solution

by:
SiddharthRout earned 500 total points
ID: 35149522
Did you try

ie.Document.all("widgets").Value = "widget1"

Sid
0
 

Author Comment

by:toecutter777
ID: 35151603
Yes this is VBA, but the problem is in the DOCTYPE declaration and I have posted it as another question. I couldn't find a VBA zone.
0
 
LVL 30

Expert Comment

by:SiddharthRout
ID: 35151935
Did you try the code that I gave?

Sid
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 

Author Comment

by:toecutter777
ID: 35153306
Yes, but I think I have a larger issue. It doesn't seem to work on a website with a doctype declaration. I am OK when it is in quirks mode.
0
 

Author Comment

by:toecutter777
ID: 35153396
This would be a VBA XHTML question
0
 

Author Closing Comment

by:toecutter777
ID: 35175886
I found out I had to run the browser in quirks mode and then it worked, so thanks!
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

MS Access 2003 or later To MySQL Migration Project Hello All, this is my second article in the category of MS-OFFICE Automation. In internet I am not able to find any comprehensive resource on the Migration of MS Access back-end to MySQL so I fin…
Lync meeting or Lync conferencing is what many organizations would like to deploy to allow them save money. But companies are now giving up for various reasons, one of which is that they cannot join external meetings (non-federated company meetings)…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now