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

Confirmation message when click rad button

5 Answers 547 Views
Button
This is a migrated thread and some comments may be shown as answers.
Prassin
Top achievements
Rank 1
Prassin asked on 24 Sep 2012, 06:05 AM
Hi All,

I need to show confirmation before performing action when i click on RadButton. 

please help.

Regards,

Prassin

5 Answers, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 2
answered on 24 Sep 2012, 07:30 AM
Hi,

Try the following code to show a confirm message in OnClientClicked event of RadButton.
aspx:
<telerik:RadButton AutoPostBack="false" ID="RadButton1" runat="server" Text="RadButton"  OnClientClicked="OnClientClicked">
</telerik:RadButton>
JS:
<script type="text/javascript">
    function OnClientClicked(button, args) {
        window.radconfirm("Are you sure you want to submit the page?");
    }
</script>
Also check this demo.

Thanks,
Shinu.
0
Prassin
Top achievements
Rank 1
answered on 24 Sep 2012, 09:02 AM
Hi Shinu,

Thanks for your replay. i have applied that code but its showing an error like "Microsoft JScript runtime error: Object doesn't support property or method 'radconfirm' "

Please clarify the error.

Regards,

Prassin
0
Accepted
Shinu
Top achievements
Rank 2
answered on 25 Sep 2012, 04:27 AM
Hi,

Please make sure that you have RadWindowManager on the page.
aspx:
<telerik:RadWindowManager ID=RadWindowManager1" runat="server"></telerik:RadWindowManager>

Thanks,
Shinu.
0
Qing
Top achievements
Rank 1
answered on 16 Aug 2019, 05:46 AM

Hi all,

     Now I face one problem for Rad Button Click and showing Message box. When I click button, the Message box left behind and not showing or prompt at once. Why ? Anybody can help me ?

0
Peter Milchev
Telerik team
answered on 20 Aug 2019, 08:21 AM

Hello Qing,

I am afraid that the provided information is insufficient to determine what exactly might be the issue. Can you please prepare a small sample project with the faulty button and send it to us in an official support ticket? That would allow us to investigate locally and help you more efficiently. 

Meanwhile, you can take a look at the built-in confirmation dialog functionality of the RadButton that is available as of R2 2019:

Regards, Peter Milchev
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Button
Asked by
Prassin
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Prassin
Top achievements
Rank 1
Qing
Top achievements
Rank 1
Peter Milchev
Telerik team
Share this question
or