p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   ASP.NET 2.0 Professional (http://p2p.wrox.com/forumdisplay.php?f=215)
-   -   Filtering Template columns in Detailsview (http://p2p.wrox.com/showthread.php?t=62187)

shashipandey September 20th, 2007 04:58 AM

Filtering Template columns in Detailsview

I am using a Detailsview control for inserting/updating the data. The detailsview has two template columns for taking two input for State and Cities using Dropdownlist. The StateDropdownlist is using StateDataSource as its datasource and CityDropdownlist is using CityDataSource's GetCityByState method as its datasource which has StateCode as its inputparameter.

All I wanted to do is to filter the citydwopdownlist based on the selection from state dropdownlist.

On CityDataSource_Selecting event I tried to pass

 e.InputParameters["StateCode"] = Convert.ToString(((DropDownList)(DetailsView1.Find Control("StateDropDownlist"))).SelectedValue);

But I am not able to filter the City List based on the State selection.

Any other way to do it?

All times are GMT -4. The time now is 12:58 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.