S
sos00
Hi guys,
i have created a user control which contains a datagrid and it's columns
will be create dynamically.
this grid is able to do Add,Edit and Delete.
because i create columns dynamically , i put columns generating code in
LoadViewState method of user control.
protected override void LoadViewState(object savedState)
{
base.LoadViewState (savedState);
Grd.DataSource = this.DataSource;
CreateColumns();
}
that's ok, but any control which cause postback will make trouble except
when it calls Grd.DataBind() method...
i try to call Grd.DataBind() method in LoadViewState() but when i do that,
Cancel and Update command buttons won't work...
what can i do ?
Thanks.
i have created a user control which contains a datagrid and it's columns
will be create dynamically.
this grid is able to do Add,Edit and Delete.
because i create columns dynamically , i put columns generating code in
LoadViewState method of user control.
protected override void LoadViewState(object savedState)
{
base.LoadViewState (savedState);
Grd.DataSource = this.DataSource;
CreateColumns();
}
that's ok, but any control which cause postback will make trouble except
when it calls Grd.DataBind() method...
i try to call Grd.DataBind() method in LoadViewState() but when i do that,
Cancel and Update command buttons won't work...
what can i do ?
Thanks.