2

I need to change the Message Box Buttons Ok and Cancel Text to Update and AddNew? Is it possible in C#.NET or I need to create a form and customize it? Kindly help me in this.

Raja Vignesh
  • 115
  • 2
  • 10
  • Create a form. From what I've seen `MessageBox` doesn't allow it, and it's not a limitation of .NET's forms implementation, it's the underlying Win32 API who doesn't allow it. – MasterMastic Apr 04 '14 at 06:01

4 Answers4

1

The MessageBox class does not provide you with option to change the button text. This codeproject article, Localizing System MessageBox allows you do that by simply adding and using the class in your project

Adil
  • 146,340
  • 25
  • 209
  • 204
1

It is possible using a MessageBoxManager.dll, which you can get in the following link,

http://www.codeproject.com/Articles/18399/Localizing-System-MessageBox

Raja Vignesh
  • 115
  • 2
  • 10
0

You cannot change the text in MessageBox Buttons.To implement the scenario you can have your custom message box.Which can be build using User Control and show it as a Dialog whenever needed.

Praveen
  • 267
  • 1
  • 9
0

Changing the text of a button on a MessageBox is not possible by default. While the text might be changeable through fake localizations, this does not seem like a good way to do it from my point of view. I encourage creating a separate form.

laptou
  • 6,389
  • 2
  • 28
  • 59