I've been searching the forum and demos for the last 2 hours now and nothing i have found has worked.
Here's my scenario
I have a radwindow popping up where the user searches for a company by name and the results are populated to a radGrid. the user then selects the correct company and the Company database ID is retrieved using the following code.
What I want to do is return the value now stored in compID to the parent page along with the contents of a text box which holds the company name. I am trying this using the following.
The window will not close when i add the values to the close function, without these values it works just fine
The closest I have come to a solution is the following demo
http://demos.telerik.com/aspnet-ajax/window/examples/clientsideevents/defaultcs.aspx?product=window
but unfortunately it doesn't show the code for the dialog popup window, which I find very strange
I have the following code server side
Here's my scenario
I have a radwindow popping up where the user searches for a company by name and the results are populated to a radGrid. the user then selects the correct company and the Company database ID is retrieved using the following code.
| protected void rGridComps_SelectedIndexChanged(object sender, EventArgs e) |
| { |
| foreach (GridDataItem item in rGridComps.MasterTableView.Items) |
| { |
| if (item.Selected) |
| { |
| compID = int.Parse(item["ID"].Text.ToString()); |
| Label1.Text = "<script>closeWin()</" + "script>"; |
| } |
| } |
| } |
| function closeWin() |
| { |
| var oWnd = GetRadWindow(); |
| alert(compID); |
| oWnd.close(compID, rtbCompName.Text); |
| } |
The closest I have come to a solution is the following demo
http://demos.telerik.com/aspnet-ajax/window/examples/clientsideevents/defaultcs.aspx?product=window
but unfortunately it doesn't show the code for the dialog popup window, which I find very strange
I have the following code server side
| function OnClientClose(sender, eventArgs) |
| { |
| if (eventArgs.get_argument() != null) |
| { |
| alert("'" + sender.get_name() + "'" + " was closed and returned the following argument: '" + eventArgs.get_argument() + "'"); |
| } |
| else |
| { |
| alert("'" + sender.get_name() + "'" + " was closed and returned no arguments'"); |
| } |
| } |