Hello,
I currently have a grid that contains a select column, then all other columns are loaded programmatically during runtime. In my grid I have a "CommandItemTemplate" section where certain buttons are located - one being "Submit". When a user selects rows, and clicks "Submit", I need to retrieve the users selections on server side.
Using the following code, I can access the data key value, but no other row data. In the example below, "myId" is correct, but the other variables are blank strings. I'm not reloading the grid on this postback, although I tried this and the same issue occurred. I tried reloading my grid on page_init and page_load - both times I still cannot access my row data. Any suggestions?
** One more thing, the "Submit" button opens a confirmation box (RadWindow) which then causes an ajax request if the user clicks "OK". Clicking "OK" calls "SetSubmitConfirmation". The button click does not fire an "ItemCommand" event, but instead, an ajax request passing an argument - InitiateAsyncRequest
I currently have a grid that contains a select column, then all other columns are loaded programmatically during runtime. In my grid I have a "CommandItemTemplate" section where certain buttons are located - one being "Submit". When a user selects rows, and clicks "Submit", I need to retrieve the users selections on server side.
Using the following code, I can access the data key value, but no other row data. In the example below, "myId" is correct, but the other variables are blank strings. I'm not reloading the grid on this postback, although I tried this and the same issue occurred. I tried reloading my grid on page_init and page_load - both times I still cannot access my row data. Any suggestions?
foreach (GridDataItem item in this.grdSummary.SelectedItems)
{
string myID = item.GetDataKeyValue("UidInt").ToString();
string myOplockColumn = item["opLock"].Text;
string myOrderColumn = item["order"].Text;
}
** One more thing, the "Submit" button opens a confirmation box (RadWindow) which then causes an ajax request if the user clicks "OK". Clicking "OK" calls "SetSubmitConfirmation". The button click does not fire an "ItemCommand" event, but instead, an ajax request passing an argument - InitiateAsyncRequest
function InitiateAsyncRequest(argument) {
var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
ajaxManager.ajaxRequest(argument);
return false;
}
function SetSubmitConfirmation(comment) {
document.getElementById('<%=hdnComment.ClientID %>').value = comment;
InitiateAsyncRequest('submit');
}