I'm using the ajaxfileupload from ajaxtoolkit. It sits inside a panel attached to the ajaxpanelextender. It works fine. I click a link inside a grid row which fires a javascript event and the panel pops up with the fileupload control.
function EditInspection(link) {
// Need to get the inspection id from code behind.
_InspectionID = link.parentNode.parentNode.cells[0].innerText;
var id = document.getElementById("ContentPlaceHolder1_InspID");
id.setAttribute('value', _InspectionID);
var modal = $('.pop')
modal.trigger('click');
}
"InspID" is an asp:hidden control inside the panel.
I select my files and click upload to get to the UploadComplete event in C#. Once I'm there I need to get a value from the InspID field. But when I get to the line
string sID = InspID.Value;
the value is always an empty string. I also tried using a regular input but the text value is also an empty string. I also tried putting the InspID control outside the panel with the same results. I looked at the API documentation and it had something specifially for passing data - context keys - but from what I've read, it's not implementd. I can't change the source code either to implement anything.
How can I set a value from the javascript call and retrieve it from the code behind?
Thank you.