10 Answers, 1 is accepted
0
Accepted
Shinu
Top achievements
Rank 2
answered on 22 May 2013, 11:34 AM
Hi Saravanan,
One suggestion is you can use the RadWindow as a RadConfirm. Please have a look at the following code I tried to display a confirm dialog on clicking a Delete RadButton.
ASPX:
JavaScript:
Thanks,
Shinu.
One suggestion is you can use the RadWindow as a RadConfirm. Please have a look at the following code I tried to display a confirm dialog on clicking a Delete RadButton.
ASPX:
<telerik:RadButton ID="RadButton1" runat="server" Text="Delete" OnClientClicking="showConfirmRadWindow" OnClick="RadButton1_Click"></telerik:RadButton><telerik:RadWindow ID="confirmWindow" runat="server" VisibleTitlebar="true" VisibleStatusbar="false" Modal="true" Behaviors="None" Height="200px" Width="300px" Title="Confirm Delete"> <ContentTemplate> <asp:Label runat="server" Text="My Label Text"> </asp:Label> <br /> <br /> <asp:Image runat="server" ImageUrl="~/Images/aud.jpg" ImageAlign="Left" /> <div style="padding-left: 30px; padding-top: 20px; width: 200px; float: left;"> <asp:Label ID="lblConfirm" Font-Size="14px" Text="Are you sure you want to Delete?" runat="server"></asp:Label> <br /> <br /> <telerik:RadButton ID="RadButtonYes" runat="server" Text="Yes" AutoPostBack="false" OnClientClicked="confirmResult"> </telerik:RadButton> <telerik:RadButton ID="RadButtonNo" runat="server" Text="No" AutoPostBack="false" OnClientClicked="confirmResult"> </telerik:RadButton> </div> </ContentTemplate></telerik:RadWindow>JavaScript:
<script type="text/javascript"> function showConfirmRadWindow(sender, args) { $find("<%=confirmWindow.ClientID %>").show(); $find("<%=RadButtonYes.ClientID %>").focus(); args.set_cancel(true); } function confirmResult(sender, args) { var oWnd = $find("<%=confirmWindow.ClientID %>"); oWnd.close(); if (sender.get_text() == "Yes") { $find("<%=RadButton1.ClientID %>").click(); } }</script>Thanks,
Shinu.
0
Saravanan
Top achievements
Rank 1
answered on 22 May 2013, 01:15 PM
This is also fine. Thanks for your prompt and quick reply.
0
Saravanan
Top achievements
Rank 1
answered on 31 May 2013, 01:15 AM
Hi Shinu,
Is it possible to add a custom image to RadConfirm? I would like to replace the ? image with my own image?
Is it possible to add a custom image to RadConfirm? I would like to replace the ? image with my own image?
0
Shinu
Top achievements
Rank 2
answered on 31 May 2013, 03:51 AM
Hi,
Try overriding the default CSS as follows.
CSS:
Thanks,
Shinu.
Try overriding the default CSS as follows.
CSS:
<style type="text/css"> .RadWindow .rwWindowContent .radconfirm { background-image: url("../Images/Image1.JPG") !important; }</style>Thanks,
Shinu.
0
Saravanan
Top achievements
Rank 1
answered on 03 Jun 2013, 12:18 PM
Hi Shinu, My page contain few radwindows. I want to access the first radwindow. How can I get the first radwindow from the group?
0
Accepted
Shinu
Top achievements
Rank 2
answered on 03 Jun 2013, 12:50 PM
Hi,
I guess you are having the RadWindows inside a RadWindowManager. Please have a look at the following code to access the first RadWindow in the RadWindowManager.
C#:
Thanks,
Shinu.
I guess you are having the RadWindows inside a RadWindowManager. Please have a look at the following code to access the first RadWindow in the RadWindowManager.
C#:
//Get a reference to the first window in the listTelerik.Web.UI.RadWindow firstWindow = WindowManager.Windows[0];Thanks,
Shinu.
0
Saravanan
Top achievements
Rank 1
answered on 05 Jun 2013, 08:17 AM
Thanks for your wonderful support. Yah, i am using radwindows inside windowmanager as your guess.
I have another requirement. I need to change the background color of the radconfirm body. Please help with the CSS.
I have another requirement. I need to change the background color of the radconfirm body. Please help with the CSS.
0
Shinu
Top achievements
Rank 2
answered on 05 Jun 2013, 09:08 AM
Hi Saravanan,
Try overriding the default CSS as follows.
CSS:
Thanks,
Shinu.
Try overriding the default CSS as follows.
CSS:
<style type="text/css"> .RadWindow .rwWindowContent { background-color:Beige !important; }</style>Thanks,
Shinu.
0
Saravanan
Top achievements
Rank 1
answered on 28 Jun 2013, 08:45 AM
Hi Shinu,
How can I place a radwindow to middle of the screen and set its size when opened using JS code?
How can I place a radwindow to middle of the screen and set its size when opened using JS code?
0
Shinu
Top achievements
Rank 2
answered on 28 Jun 2013, 09:44 AM
Hi Saravanan,
Please try the following JavaScript.
JavaScript:
Thanks,
Shinu.
Please try the following JavaScript.
JavaScript:
<script type="text/javascript"> function openRadWindow() { var oWnd = var oWnd = radopen ("http://www.google.com", "RadWindow1"); oWnd.setSize(315, 250); oWnd.Center(); }</script>Thanks,
Shinu.