Updating Table with DropDownList Selection (ASP)
I'm converting one of my Access forms into ASP and I'm having trouble mimicking Access's combobox features in ASP.
In my original form, I have a combobox bound to a lookup table that writes the selection into a master table field.
The combobox works like this in Access:
Row Source: SELECT sourceCodes.name FROM sourceCodes;
Control source: source (a field in my master table)
In Dreamweaver, I was able to populate a DropDownList with the same query as a Dataset ('sourceDropDown'):
<asp:DropDownList ID="DropDownList1" DataSource="<%# sourceDropDown.DefaultView %>" DataTextField="name" DataValueField="code" runat="server"></asp:DropDownList>
But I'm at a lack of how to write this data when a selection is made. The ASP page I'm making is set up to be an update form by default. How do I tie a combobox change into the update action or do I do something like an AfterUpdate for the DropDownList to write the selection back to the table immediately?
Goes without saying that I'm new to ASP. Any help or even pointers in the right direction would be really appreciated!
Thanks in advance!
[Subject line edited by moderator to indicate server technology used]
