I have a RadGrid on a page that contains a custom ImageButton control in the first column of each row. When I press the button I call the following javascript function:
What I want to do when this button is pressed is a) save any data that may have already been entered into the grid and b) add a row based on the saved data to the RadGrid's DataSource and rebind it.
So if the table has two rows and they click the button I want to add a third row on the server and have that be added to the grid after the partial page postback.
I'm having two problems. The first is that the data entered client-side is not accessible from the server-side instance of the grid so I cannot save that data. The data does appear if I put a simple button on the page that forces the whole page to postback. Why does it not work here?
The second problem is that when I rebind the grid server-side with a new row those changes are not reflected on the client. Is there something special I have to do to update the grid when using the Ajax Manager?
Thank you.
function AddDetailRowButtonClicked(id) |
{ |
var ajaxManager = $find("<%= RadAjaxDetailManager.ClientID %>"); |
ajaxManager.ajaxRequest(id); |
} |
What I want to do when this button is pressed is a) save any data that may have already been entered into the grid and b) add a row based on the saved data to the RadGrid's DataSource and rebind it.
So if the table has two rows and they click the button I want to add a third row on the server and have that be added to the grid after the partial page postback.
I'm having two problems. The first is that the data entered client-side is not accessible from the server-side instance of the grid so I cannot save that data. The data does appear if I put a simple button on the page that forces the whole page to postback. Why does it not work here?
The second problem is that when I rebind the grid server-side with a new row those changes are not reflected on the client. Is there something special I have to do to update the grid when using the Ajax Manager?
Thank you.