MessageBox with custom background color
-
I have researched adding a MessageBox to an application. However the sealed class does not give you much. The solution is always to create your own. I figure you could use the Win32 Version and import it into C#. but that does not take care of the background color. in MFC you call setdlgBackColor or something like that and the entire application is converted to the new color (skin). in C# you do not have that. is this exposed in VB.NET? I was thinking I could link in a VB.NET DLL with the functionality. still there are several dialogs in windows that act this way. one of them is the fileopen dialog. does anyone have an elegant solution that does not involve recoding the entire functionality, LOL, of the dialog / MessageBox in question? there are many people on the web running into this problem, especially if they are skinning their apps or providing custom colors for customer requirements. Thanks -Pete
-
I have researched adding a MessageBox to an application. However the sealed class does not give you much. The solution is always to create your own. I figure you could use the Win32 Version and import it into C#. but that does not take care of the background color. in MFC you call setdlgBackColor or something like that and the entire application is converted to the new color (skin). in C# you do not have that. is this exposed in VB.NET? I was thinking I could link in a VB.NET DLL with the functionality. still there are several dialogs in windows that act this way. one of them is the fileopen dialog. does anyone have an elegant solution that does not involve recoding the entire functionality, LOL, of the dialog / MessageBox in question? there are many people on the web running into this problem, especially if they are skinning their apps or providing custom colors for customer requirements. Thanks -Pete
-
This article[^] has some good suggestions.
This is a great Article - Thanks! I could not figure out how to change the background color though. I did not see anything in the code of the project that allowed you to do that. -Pete
-
This is a great Article - Thanks! I could not figure out how to change the background color though. I did not see anything in the code of the project that allowed you to do that. -Pete
peterdrozd wrote:
I could not figure out how to change the background color though.
You could try posting your question on the article forum to see if the author has any idea. I suspect you may find it quicker just to use a custom dialog with all your own controls and formats.
-
I have researched adding a MessageBox to an application. However the sealed class does not give you much. The solution is always to create your own. I figure you could use the Win32 Version and import it into C#. but that does not take care of the background color. in MFC you call setdlgBackColor or something like that and the entire application is converted to the new color (skin). in C# you do not have that. is this exposed in VB.NET? I was thinking I could link in a VB.NET DLL with the functionality. still there are several dialogs in windows that act this way. one of them is the fileopen dialog. does anyone have an elegant solution that does not involve recoding the entire functionality, LOL, of the dialog / MessageBox in question? there are many people on the web running into this problem, especially if they are skinning their apps or providing custom colors for customer requirements. Thanks -Pete
You must have to write a custom control to do that...