We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

There are a way to change the text on Yes / No Buttons, inside a MessageBox question ?

Thread ID:

Created:

Updated:

Platform:

Replies:

131617 Jul 19,2017 09:39 PM UTC Aug 1,2017 04:04 AM UTC WinForms 3
loading
Tags: MessageBoxAdv
Christopher
Asked On July 19, 2017 09:39 PM UTC

I am using MessageBoxAdv to show a question but the buttons does not take the O.S. language it shows on english by default, and the O.S. is in spanish and it shows on english.

Mallika Kannan [Syncfusion]
Replied On July 20, 2017 07:23 AM UTC

Hi Christopher   
   
Thank you for contacting Syncfusion support.   
   
Yes, this reported “MessageBoxAdv Localization” behavior can be achieved by using the ILocalizationProvider Interface.   
   
Please make use the below Code example.   
   
Code example  
   
// Codes in localizer class file   
    internal class localizer : ILocalizationProvider   
    {   
        public string GetLocalizedString(CultureInfo culture, string name, object ctrl)   
        {   
            #region Localization   
   
            switch (name)   
            {   
                #region MessageBoxAdv   
                ///<summary>    
                ///OK Button in Spanish Language    
                ///</summary>   
                case ResourceIdentifiers.OK:   
                    return "De acuerdo";   
   
                ///<summary>   
                ///Cancel Button in Spanish Language   
                ///</summary>                       
                case ResourceIdentifiers.Cancel:   
                    return "Cancelar";   
   
                ///<summary>   
                /// default   
                ///</summary>   
                default:   
                    return string.Empty;   
                    #endregion   
            }   
            #endregion   
        }   
   
//Codes In Form1.cs   
   
LocalizationProvider.Provider = new localizer();   
   
//MessageBox show   
MessageBoxAdv.Show("Metro Theme Anpassung""Das ist Syncfusion MessageBoxAdv Control", System.Windows.Forms.MessageBoxButtons.OKCancel);   
   
Screenshot   
   
     
   
We have also prepared the sample and video for your reference. It can be downloaded from the below link.   
   
   
   
Kindly check this above solution and let us know if it is helpful.   
   
Regards,   
Mallika  
 


Christopher
Replied On July 31, 2017 02:19 PM UTC

Thankyou so mouch Mallika!, it works perfectly!, greetings.


Mallika Kannan [Syncfusion]
Replied On August 1, 2017 04:04 AM UTC

Hi Christopher 
 
Thanks for your update.  
 
We are glad to hear that we have helped you in this.  
 
Please let us know if you need any other assistance.  
 
Regards,               
Mallika 
 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;