Transfer DataTable Between RadParentWindow And Child Window

487 Views Asked by At

I have a RadWindow, in that rad window there is a button that will popup another radwindow. (Inside the parent window,and it is a different page). I should be able to send my datatable to Parent radwindow after closing the child radwindow. Any suggestions?

1

There are 1 best solutions below

0
On BEST ANSWER

This greatly depends on your setup and the data you need to pass. Here is a brief overview:

  • you have a server object and you cannot pass the data through JavaScript: Devise a way to store the data on the server (e.g., in the Cache or Session) so you can access it later in the parent page.

  • You can pass the data via JavaScript: In this case you can simply handle the RadWIndow's OnClientClose event to get the data and pass it to its close() method from the content page, as shown here: http://www.telerik.com/help/aspnet-ajax/window-client-side-events-onclientclose.html.

In either case, you should use the OnCLientClose event to either work with your data on the client (see this demo http://demos.telerik.com/aspnet-ajax/window/examples/dialogreturnvalue/defaultcs.aspx), or to initiate a postback on the first dialog that will work with the data on the server.

This demo will show you a slightly different way of going through the server and then performing an AJAX request to update the first page: http://demos.telerik.com/aspnet-ajax/controls/examples/integration/gridandwindow/defaultcs.aspx?product=window.