example for messagebox which stops the code behind thread

6 posts, 0 answers
  1. Baris
    Baris avatar
    34 posts
    Member since:
    Jul 2013

    Posted 11 Mar 2014 Link to this post

            <telerik:RadWindowManager ID="RadWindowManager1" runat="server">
                <Windows>
                    <telerik:RadWindow ID="modalPopup" runat="server" Width="360px" Height="360px" Modal="true" Behaviors="Close"   >
                        <ContentTemplate>
                            <div >
                                <table cellspacing="0" cellpadding="0" class="info" width="100%">
                                    <tr>
                                        <td align="center" valign="middle" height="175">Pages are about to exit, do you want to save?
                                        </td>
                                    </tr>
                                </table>
                                <div class="bottom-buttons cf">
                                    <div class="fr">
                                        <a href="#" class="button cancel">Cancel</a>
                                        <a href="#" class="button button-pink">Save</a>
                                    </div>
                                </div>
                            </div>
                            <asp:Button ID="Button2" runat="server" Text="Button" />
                        </ContentTemplate>
                    </telerik:RadWindow>
                </Windows>
            </telerik:RadWindowManager>

    But In this radwindow, I can be show it in page but I need when this pop is shown at sth in codebehind, code behind must be stop and must wait pop up result. In this radwindow message box shown but code is resuming. I need a message box like      asp messagebox.show("sth"); because I need to wait pop up result. Can you give me example like that ? Note: messagebox must inculde item template property.


  2. Marin Bratanov
    Admin
    Marin Bratanov avatar
    3599 posts

    Posted 11 Mar 2014 Link to this post

    Hello,

    This help article explains how to achieve this and what must be kept in mind in the process: http://www.telerik.com/help/aspnet-ajax/window-using-radconfirm-in-server-code.html.


    Regards,
    Marin Bratanov
    Telerik

    DevCraft Q1'14 is here! Watch the online conference to see how this release solves your top-5 .NET challenges. Watch on demand now.

  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Baris
    Baris avatar
    34 posts
    Member since:
    Jul 2013

    Posted 12 Mar 2014 in reply to Marin Bratanov Link to this post

    When ı used radconfirm  code isn't stop at codebehind. Dialog must be open and must wait a result in code. Also I need take result at code behind not js. Can you write a example for me
  5. Raman
    Raman avatar
    18 posts
    Member since:
    Aug 2012

    Posted 13 Mar 2014 in reply to Baris Link to this post

    Hello Baris

    Is your problem solved... if solved can you please explain how u have done this.
  6. Baris
    Baris avatar
    34 posts
    Member since:
    Jul 2013

    Posted 13 Mar 2014 Link to this post

    No I can't find solution for this. If I find, I will share with u.
  7. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 13 Mar 2014 in reply to Baris Link to this post

    Hi Baris,

    Unlike regular browser counterpart, the RadConfirm dialog is non-blocking,it's designed to respond via a callback. At a minimum the RadConfirm function takes two arguments, one HTML string with the message, and the name of a callback function that deals with the results. The callback takes a single parameter, whose value is True or False, depending on whether the user clicks "OK" or "Cancel". The RadConfirm returns the client result as an argument in its Callback function only, as opposed to the standard browser confirm() function - the radconfirm() function returns a reference to the RadWindow dialog that is created and not the result. The callback function is a client-side JavaScript function which is executed when the dialog is closed. Please have a look into the this help documentation  for further information.

    Thanks,
    Princy.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017