Hi Giorgio,
Thank you for your update.
I am researching the testing sample now. More time is needed for this
issue. Thank you for your understanding. I will contact you as soon as
possible.
Best regards,
Jacob Yang
Microsoft Online Partner Support
Get Secure! -
www.microsoft.com/security This posting is provided "as is" with no warranties and confers no rights.
________________________________________
From: Giorgio Parmeggiani [mailto:gipasoft@inwind.it]
Sent: October 12, 2003 1:27
To: Jacob Yang
Subject: Example of adding a control to the DataGrid controls collection
Hi Jacob
Thanks for your rapids answer!
I have prepared an simple example of the DataGrid Custom.
The class calls DataGridFilter (contained in DataGridFilterExample.zip) and
is used in the example page default.aspx (contained in
DataGridFilterTest.zip).
Calling the page default.aspx is loaded a DataGrid reading the table
"Clienti" of Northwind.mdb (it uses the database that I have attached)
In the DataGrid custom I have defined 4 columns (BoundColumnFilter extended
by BoundColumn) in base to which a panel of filter is created above to the
DataGrid.
Every column have an attribute that establishes if he must be visualizes in
the filter as TextBoxFilter (class extended by TextBox) or DropDownFilter
(class extended by DropDownList). I have foreseen in the example page three
columns as TextBox and the last as DropDown.
You can easily verify that, performing a postback, the TextBox maintains
his value thanks to the ViewState while the DropDown doesn't maintain it (I
am forced to recall the method "setChildDataSource" with the parameter
load=true to manually load the element selected through Request.Form)
Besides if you put a BreakPoint inside the method OnPreRender of
DropDownFilter you can easily verify that this is never recalled.
Where am I wrong? Can you advise me to resolve the problem?
Thanks still for your interest to my problem.
Ciao
Giorgio
P.S. The example that I have sent you doesn't filter the elements of the
DataGrid I have removed this it seems for simplifying him/it.