RADPrompt OK/ Cancel not working

2 posts, 0 answers
  1. Prachi
    Prachi avatar
    16 posts
    Member since:
    Jun 2012

    Posted 28 Nov 2012 Link to this post


    I have a sharepoint 2010 web part.
    I am calling RAD prompt from code behind on a button click as follows :





    RadWindowManager1.RadPrompt("Press Ok to submit for approval", "promptCallBackFn", 330, 160, null, "Note to PM on what was changed", "");

    and the function definition is  as follows:





    function promptCallBackFn(arg) {
          if (arg) //the user clicked OK
              __doPostBack("<%=hdnbtnGetComment.UniqueID %>", arg);

    THe RAdprompt screen is opening correctly but The OK, Cance button is not working. It will not close the prompt on clicking either ok or Cancel. Internet version is IE8

  2. Marin Bratanov
    Marin Bratanov avatar
    5908 posts

    Posted 03 Dec 2012 Link to this post

    Hi Prachi,

    Can you confirm that there are no dropped requests for the webresources (i.e. the RadWindow and RadWindowManager scripts are loaded properly)? Is there another JavaScript error before this, as it would break the further execution of the scripts? If there are some of the above issues you may find useful this help article an this one as well. Such issues can occur if a firewall (or antivirus, or other similar software) blocks some resources - either on the server, or on the client, so it can be an isolated case of an improperly configured client machine/network.

    I have not seen such an issue before (of course, assuming all scripts are loaded and there isn't a JS error) and I am not sure what the reason for this behavior may be. Please check whether the ID of the RadConfirm is passed correctly to the button event handlers (see attached screenshot). Can you also confirm that the ClientIDMode of the RadControls on the page is left to AutoID and is not overriden to Static, for example?

    In the meantime you can use a regular RadWindow and declare buttons in its ContentTemplate as well as a span to place the text and use it instead of the RadConfirm. You can show it from the server as described in this thread. You can take the HTML used by default to get the same appearance from this help article. You can also try overriding the built-in template for the prompt - replace the more complex buttons we use with regular inputs with the same onclick handler and see if this helps.

    Kind regards,
    Marin Bratanov
    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.
Back to Top