I have a RadGrid that loads from a DataTable pulled from my database. The user can click a "Refresh" button on the page that will update the database behind the scenes, then update various labels on the page as well as the RadGrid from the new database entries, all through RadAjax. The labels correctly update, but the problem comes when I call RadGrid1.Rebind();
The "Refresh" click code sets two global variables in the codebehind and then uses those values in updating the page. Then Rebind() gets called at the end of the function, and in the process, processes each row of the grid. One column in each row calls a function that uses one of the global variabes set earlier to genereate an image URL. However, even though the same global variable was accessible in the Callback code, in the Rebind code it is suddenly NULL. I get a Javascript error and the RadGrid doesn't get updated.
Summary: How do I set variables in my RadAjax callback function that will be accessable by the functions Rebind calls when repopulating my RadGrid?
Thanks in advance for your help.
The "Refresh" click code sets two global variables in the codebehind and then uses those values in updating the page. Then Rebind() gets called at the end of the function, and in the process, processes each row of the grid. One column in each row calls a function that uses one of the global variabes set earlier to genereate an image URL. However, even though the same global variable was accessible in the Callback code, in the Rebind code it is suddenly NULL. I get a Javascript error and the RadGrid doesn't get updated.
Summary: How do I set variables in my RadAjax callback function that will be accessable by the functions Rebind calls when repopulating my RadGrid?
Thanks in advance for your help.