S
Sam
A) Destination Table with 4 Fields.
1) Last Name
2) First Name
3) State
4) Zip Code.
B) Look up table State/Zip Code with 2 Fields
1) State
2) Zip Code.
I created a DetailView Form in Asp.net to Insert/Update Destination
Table. Destination Table's State and Zip Code Fields are converted from
Bound Column to Item/Edit/Insert Template, Created 2 Drop Down Lists,
DDLState and DDLZIP. I am using '<%# Bind(...)%>' for both of them.
Also, I do have 2 SQLDatasource for DDL's (i.e. SqlState for DDLState
and SqlZip for DDLZIP).
My Intention is very simple:
When user select State Name from DDLState DropDownList List (example:
NJ), in DDLZIP Dropdown list it must show only Zip Codes from that
State. In order to Change the Value of DDLZIP, users must Change the
Value of DDLState. Basically DDLZIP is Child/Dependant of DDLState. I
did correctly setup proper reference to DDLState in SelectedParameters,
Control Parameters, PropertyName in SqlZip (SqlDataSource for DDLZIP).
This Cascading dropdown logic does work Fine in a Form without a
DetailView. I tested it. But I am having hard time to implement this
within Detail View.
Any Complete Example (i.e. Form with Subs) will be highly appreciated.
I will be glad if this example is based on NorthWind Database.
Thanks a lot for your time and efforts.
- Sam
1) Last Name
2) First Name
3) State
4) Zip Code.
B) Look up table State/Zip Code with 2 Fields
1) State
2) Zip Code.
I created a DetailView Form in Asp.net to Insert/Update Destination
Table. Destination Table's State and Zip Code Fields are converted from
Bound Column to Item/Edit/Insert Template, Created 2 Drop Down Lists,
DDLState and DDLZIP. I am using '<%# Bind(...)%>' for both of them.
Also, I do have 2 SQLDatasource for DDL's (i.e. SqlState for DDLState
and SqlZip for DDLZIP).
My Intention is very simple:
When user select State Name from DDLState DropDownList List (example:
NJ), in DDLZIP Dropdown list it must show only Zip Codes from that
State. In order to Change the Value of DDLZIP, users must Change the
Value of DDLState. Basically DDLZIP is Child/Dependant of DDLState. I
did correctly setup proper reference to DDLState in SelectedParameters,
Control Parameters, PropertyName in SqlZip (SqlDataSource for DDLZIP).
This Cascading dropdown logic does work Fine in a Form without a
DetailView. I tested it. But I am having hard time to implement this
within Detail View.
Any Complete Example (i.e. Form with Subs) will be highly appreciated.
I will be glad if this example is based on NorthWind Database.
Thanks a lot for your time and efforts.
- Sam