Information générale
Catégorie:
The Mere Mortals .NET Framework
You can override the factory method that is used to create the mmMessageBoxForm object. There are actually three overrides for this method you may want change (you can look at mmFactoryDesktop.cs for all the methods).
I believe for this particular message add this to your factory.cs.
using System.Windows.Forms;
using OakLeaf.MM.Main.Windows.Forms;
public class Factory : OakLeaf.MM.Main.Windows.Forms.mmFactoryDesktop
{
public override mmMessageBoxForm CreateMessageBoxForm(string message, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, object languagePK)
{
// override the caption here...
return new mmMessageBoxForm(message, "Your Caption Here",
buttons, icon, languagePK);
}
>When I close a form and get the messagebox asking whether to save changes, the title of the MessageBox is "Application Message" - where can I override that text?
>
>Note for lurkers, I know how to change the title of a messagebox, I'm asking for how to override the caption in the messagebox that MM uses by default in its framework
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement