Asp:DropDownList simple question. Need help.

S

Shapper

Hello,

I have a function in my aspx.vb file which changes culture:

Function Change_Culture(newCulture As String)
....

When a drop down list item is selected I want automatically to call the
function Change_Culture(Item.Value that was choose in the dropdownlist).

Can someone help me out?

Thanks,
Miguel
 
G

garethdjames

add an event handler for the drop down list, in the code do this

private void DropDownList1_SelectedIndexChanged(object sender,
System.EventArgs e)
{
Change_Culture(DropDownList1.SelectedValue);
}
 
G

garethdjames

if you want the form to post when you select an option on the drop down
then yes, if you want to click a button to confirm the selection then no
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top