Dynamic Weblist(Dropdown) in web application

Paddy_

New Member
Joined
Jan 29, 2010
Messages
13
Hi,

I am working on this web application which has a dynamic drowdown.

Its like this, If I choose a value in the first drop down in the webpage, the second drops displays the values according to the value chosen in the first dropdown.

The problem is for the second dropdown the values are not show in the source code. The code that is dispalyed is

HTML:
             <select name="ctl00$ContentPlaceHolder1$fs_AccountReq$fv_ra$I_FS_ProductTypeDDL" id="ctl00_ContentPlaceHolder1_fs_AccountReq_fv_ra_I_FS_ProductTypeDDL">
     <option value=""></option>
    </select>
            <input type="hidden" name="ctl00$ContentPlaceHolder1$fs_AccountReq$fv_ra$cddProductType_ClientState" id="ctl00_ContentPlaceHolder1_fs_AccountReq_fv_ra_cddProductType_ClientState" />

I am not sure how to choose the value in this second dropdown using VBA(Excel programming/Macro) since it is a dynamic dropdown.

Suppose I want the Value "A" in the second dropdown, I have tried the code
Code:
objIE.document.getelementbyid("ctl00_ContentPlaceHolder1_fs_AccountReq_fv_ra_I_FS_ProductTypeDDL").Value = "A"


But it doesn't seem to work.

Any suggestions is welcome. Please help me out.
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.

Forum statistics

Threads
1,215,063
Messages
6,122,935
Members
449,094
Latest member
teemeren

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top