Radwindowmanager confirmation server side

3 posts, 1 answers
  1. Shakti SIngh Dulawat
    Shakti SIngh Dulawat avatar
    89 posts
    Member since:
    Oct 2009

    Posted 05 Sep 2012 Link to this post

    Dear friends,
    I am using radwindowmanager in asp.net
    can some one please give me a good idea how to using radwindowmanager confirmations message at server side!
    Some thing like 

    Have two buttons on the dialog which are “Scan Another” and “Translate”. Scan Another will

    clear the scanned bet image and reset the stake to £0.00. Translate will go immediate to the

    translate tab with that bet selected. 

    This is what right now I am using!

    <telerik:radwindowmanager id="RadWindowManagerTakeBet" runat="server" skin="Metro">
    </telerik:radwindowmanager>

    RadWindowManagerTakeBet.RadAlert("Stake Saved!", 330, 100, "No Bet Stake", null, null);





    Thanks,
    Shakti

  2. Answer
    Eyup
    Admin
    Eyup avatar
    3015 posts

    Posted 10 Sep 2012 Link to this post

    Hello Shakti,

    You can get the result from the RadConfirm or RadAlert only on client-side. And according to the user's selection you could fire a command with the corresponding outcome. For example:
      mark-up:
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
    </telerik:RadAjaxManager>
    <telerik:RadWindowManager ID="RadWindowManagerTakeBet" runat="server" Skin="Metro">
    </telerik:RadWindowManager>
    <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" />
      JavaScript:
    function confirmCallBackFn(arg) {
        var ajaxManager = $find("<%=RadAjaxManager1.ClientID%>");
        if (arg) {
            ajaxManager.ajaxRequest('TranslateConfirmed');
        }
        else {
            ajaxManager.ajaxRequest('TranslateRejected');
        }
    }
      C#:
    protected void Button1_Click(object sender, EventArgs e)
    {
        RadWindowManagerTakeBet.RadConfirm("Are you sure to translate?", "confirmCallBackFn", 300, 100, null, "My Confirm");
    }
    protected void RadAjaxManager1_AjaxRequest(object sender, Telerik.Web.UI.AjaxRequestEventArgs e)
    {
        if (e.Argument == "TranslateConfirmed")
        {
           // execute custom logic
        }
    }

    I hope this will prove helpful.

    Kind regards,
    Eyup
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Shakti SIngh Dulawat
    Shakti SIngh Dulawat avatar
    89 posts
    Member since:
    Oct 2009

    Posted 13 Sep 2012 Link to this post

    Wonderful Solutions work Perfect!

    Thanks,
    Shakti
Back to Top