This is a migrated thread and some comments may be shown as answers.

How to postback master page / client page

1 Answer 326 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Darren
Top achievements
Rank 1
Darren asked on 06 Mar 2014, 04:30 PM
I am following the demo to export a radscheduler to a calendar, but I am running into a problem using master pages and content pages. I have the RadAjaxManager in the masters page and RadAjaxManagerProxy in the content page.  I am getting an error trying to do the following (code is in the content page):

    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">
            function Export(sender, e) {
                $find("<%= RadAjaxManager1.ClientID %>").__doPostBack(sender.name, "");
            }
        </script>
    </telerik:RadCodeBlock>

I have this in the scheduler:
<asp:Button runat="server" ID="Button1" CssClass="rsExportButton" ToolTip="Export to iCalendar"
                                CommandName="Export" OnClientClick="Export(this, event); return false;" Style="cursor: pointer; cursor: hand;"></asp:Button>

I know I am not doing this right but I don't know what to reference properly in the javascript.

Thanks!
 

1 Answer, 1 is accepted

Sort by
0
Darren
Top achievements
Rank 1
answered on 06 Mar 2014, 09:53 PM
I solved my own problem by using:

$find("<%= RadAjaxManager.GetCurrent(Page).ClientID %>").__doPostBack(sender.name, "");
Tags
Ajax
Asked by
Darren
Top achievements
Rank 1
Answers by
Darren
Top achievements
Rank 1
Share this question
or