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

Dialog

1 Answer 47 Views
Window
This is a migrated thread and some comments may be shown as answers.
Saravanan
Top achievements
Rank 1
Saravanan asked on 24 May 2013, 12:54 AM
Hi,

There is a Enter Promocode link button on my page. On Clicking this button, I need to display a small dialog box asking the user to enter code. Once the user enter the code, I need to pass it to another JavaScript function? For this, I dont need RadWindow with contenttemplate.

Thanks,
Saravanan.

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 24 May 2013, 03:27 AM
Hi

You can use a RadPrompt to achieve your requirement. In order to use this dialog you need to have a RadWindowManager on the page. Please have a look at the following code I tried which works fine at my end.

ASPX:
<telerik:RadWindowManager ID="RadWindowManager1" runat="server" Skin="Windows7">
</telerik:RadWindowManager>
<telerik:RadButton ID="RadButton1" runat="server" Text="Enter PromoCode" ButtonType="LinkButton" AutoPostBack="false"
    OnClientClicked="OnClientClicked">
</telerik:RadButton>

JavaScript:
<script type="text/javascript">
    function OnClientClicked(sender, args) {
        radprompt('Enter Promo Code', promptCallBackFn);
    }
    function promptCallBackFn(arg) {
        alert("The Promo Code you entered is : " + arg);
    }
</script>

Thanks,
Shinu.
Tags
Window
Asked by
Saravanan
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or