Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET AJAX > Window > RADConfirm Src icon change..

Answered RADConfirm Src icon change..

Feed from this thread
  • Sreenivas avatar

    Posted on Jul 22, 2009 (permalink)

    Hi,

    We are using latest version of Teleriks. I want to change the question icon to my own icon on RadConfirm window.

    Please note: Telerik.Web.UI.dll is referenced and we are not using skin folder in the root directory of the application

    Need a solution to change the icon with out changing in xml file.

    Thanks
    Sreenivas.

    Reply

  • Answer Fiko Fiko avatar

    Posted on Jul 27, 2009 (permalink)

    Hello Sreenivas,

    Yes, you just need to add the following CSS declaration in the title tag of the page that contains the RadWindowManager's declaration :

    <style type="text/css"
        .rwDialogPopup.radconfirm 
        { 
            background-imageurl('ajax-loader.gif') !important; 
        } 
    </style> 

    The value that is passed to the url is the path to the image that will replace the standard question image.
    I hope this helps.

    Greetings,
    Fiko
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.

    Reply

  • Say Hello to Telerik's PivotGrid for ASP.NET AJAX, Silverlight, WPF and WinForms. Now packed with OLAP support.
  • Sreenivas avatar

    Posted on Jul 27, 2009 (permalink)

    Thanks for your reply. This works perfectly. Also, I have tried in a different way.

     

    <style type="text/css">

     

     

    .RadWindow .rwWindowContent .radconfirm

     

    {

     

    background-image: url('../../images/stop.gif');

     

     

    background-position: left top;

     

    }

     

    </style>


    Regards
    Sreenivas
    Montvale KPMG.

     

    Reply

  • L avatar

    Posted on May 4, 2012 (permalink)

    Hi Fiko,

    I know this thread is old but your answer helped me a lot.

    Still I have another problem, this is my scenario.
    I have to radalert calls in the same page. I want to show the warning icon in one of them, and an information icon in the other one. 

    function ShowWarningIcon() {
           radalert(document.getElementById('<%= confirmationMsg.ClientID %>').value, 430, 100, document.getElementById('<%= confirmationTitle.ClientID %>').value, alertCallBackFn, null); return false;
    }
     
    function ShowInformationIcon() {
           radalert(document.getElementById('<%= confirmationMsg.ClientID %>').value, 430, 100, document.getElementById('<%= confirmationTitle.ClientID %>').value, alertCallBackFn, null); return false;
    }


    Thanks in advance for your help.

    Reply

  • Marin Bratanov Marin Bratanov admin's avatar

    Posted on May 4, 2012 (permalink)

    Hi,

    I am glad to inform you that since Q1 2012 this feature is supported out of the box by the RadAlert and RadConfirm. You only need to pass the URL to the desired image as the last parameter of the method. You can see it in action in the following online demo: http://demos.telerik.com/aspnet-ajax/window/examples/browserdialogboxes/defaultcs.aspx.
    The full syntax is as follows:
    radalert(text, oWidth, oHeight, oTitle, callbackFn, imgUrl);

    and is explained in this help article: http://www.telerik.com/help/aspnet-ajax/window-dialogs-alert.html.

    On older versions you would need to store a reference to the alerts and change the background image via JavaScript, e.g. by using jQuery:
    var oAlert = radalert();            
    var contentElement = $telerik.$(".radalert", oAlert.get_popupElement());//gets a reference to the content container where the image is set as a background image
    contentElement.css("background-image", "url('custom-content-icon.png')");//changes the background image with a custom one



    Greetings,
    Marin
    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.

    Reply

  • L avatar

    Posted on May 7, 2012 (permalink)

    Thanks for the reply. This solution didn't work for me. I used Fiko's solution at the end and now all radalerts are showing the same icon.

    Reply

  • Say Hello to Telerik's PivotGrid for ASP.NET AJAX, Silverlight, WPF and WinForms. Now packed with OLAP support.

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET AJAX > Window > RADConfirm Src icon change..
Related resources for "RADConfirm Src icon change.."

ASP.NET Window Features  |  Documentation  |  Demos  |  Step-by-step Tutorial  ]