RadConfirm not displaying

3 posts, 0 answers
  1. Matt
    Matt avatar
    29 posts
    Member since:
    Oct 2011

    Posted 26 Mar 2012 Link to this post

    I'm trying to use RADConfirm for the first time calling it from my codebehind.
    I'm using Q1 of RadControls, .Net 4.0, VS 2010.

    I have a web form with a button on it. In a function called by the button click event, I put the following:
                RadWindowManager1.RadConfirm("Are you sure?", "confirmCallBackFn", 300, 100, null, "Delete all messages?");

    On the page I have a asp:ScriptManager, a telerik:RadAjaxManager, and a telerik:RadWindowManager.

    In the debugger I can see the line with the RADConfirm does get executed but I never see anything pop up in the browser. Am I making a rookie mistake? Please enlighten me.

    Also, once I can get it to show up, what gets returned? True or False, yes? Could I do something like:

    if (RadWindowManager1.RadConfirm("Are you sure?", "confirmCallBackFn", 300, 100, null, "Delete all messages?"))
       //delete the messages

  2. Marin Bratanov
    Marin Bratanov avatar
    3907 posts

    Posted 28 Mar 2012 Link to this post

    Hello Matt,

    Please look for JavaScript errors on your page that can be preventing the radconfirm from executing properly. For example, a missing callback function can throw an error. Please try to resolve it and if you are unable post some runnable code that can replicate it so we can help you. You may also find useful this article for future use of the server method.

    Please also check for some global CSS rules or class overrides that may be interfering with the RadWindow. This is easiest done by removing all your custom CSS from the page and if the issue is gone then you can easily find the offending rule by re-adding them one by one.

    As for the return type and handling the user input - please examine this article: http://www.telerik.com/help/aspnet-ajax/window-dialogs-confirm.html. It explains that the result is returned in the callback function as a parameter and that it depends on the clicked button (true, false and null for the ok, cancel and [x] respectively). You can also see it in action in this online demo: http://demos.telerik.com/aspnet-ajax/window/examples/browserdialogboxes/defaultcs.aspx.

    To transfer this to the server you can either invoke an AJAX request through the RadAjaxManager, or use the __doPostBack() function to either click on a hidden button (which one may depend on the value) that will execute the needed server-side mehod, or you can store the user response in a hidden field and look for it in the PageLoad server event.

    Kind regards,
    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. lalit
    lalit avatar
    1 posts
    Member since:
    Jan 2014

    Posted 10 Feb 2014 in reply to Marin Bratanov Link to this post

    check you are using RadWindowManager on aspx page or not
Back to Top