I have created a nice looking application using infagistic controls that have a common look across all the controls and forms using the Office2007Blue Style. The problem is that I need to pop up message boxes from time to time and the message boxes are being displayed in the standard windows style and not following the style used in the rest of my application. Is there anyway to make standard MessageBox (found in System.Windows.Forms) follow the styling used in the rest of the application?
I am using NetAdvantage for Windows Forms 2008 Vol. 1 Bundle and apologize if this is not the correct place for it, I was not sure what to put this under.
Hi,
No, unfortunately, the DotNet MessageBox class does not allow any sort of styling. You could, of course, create your own MessageBox dialog using Infragistics controls or InBox controls with an InboxControlStyle on it.
What would be really great is if Infragistics had an UltraMessageBox component. You can Submit a feature request to Infragistics for one and maybe it will be added in a future release. :)
The UltraMessageBox is available now in version 2010.1, how can I set the InboxControlStyle?
Using the following code:
UltraMessageBoxManager umbm = new UltraMessageBoxManager(); umbm.ShowMessageBox(new UltraMessageBoxInfo(MessageBoxStyle.Default, this, "Test MessageBox", "This Is A Test", MessageBoxButtons.OK, MessageBoxIcon.Information, MessageBoxDefaultButton.Button1, Infragistics.Win.DefaultableBoolean.False));
Results in the following:
So, not sure what I am doing wrong. If your UltraMessageBox has blue rounded corners like the rest of the Office2007Blue theme, please send me the portion of the isl file that styles the UltraMessageBox so I can paste it in mine.
So you want to change the borders of the MessageBox form to look like an Office2007 window with rounded corners? There's currently no way to do that.
Not to sound too crass but then what was this supposed to mean?
"The Office2007Blue.isl file contains styling information for the UltraMessageBox. I just double-checked to make sure, and it works fine for me.
So... if it's not working for you, then my first guess is that you are not using UltraMessageBox, but are instead using the inbox MessageBox."
It's styling the contents of the messagebox, not the dialog itself. I didn't realize that's what you wanted.
Hi all,
I'd like to know if there have been some improvements in this sense lately. Last post is dated 4 years ago. I'd like to apply my application style to every form, including messageBox. Is there a way to do this?
Thanks in advance
Valentina