Custom MessageBox

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,
I want to create a customized MessageBox. In .net the MessageBox
class will wrap the SDK MessageBox. And it has a private constructor. So
surely I cant derive from the MessageBox class.
So I tried deriving the messageBox class from System.Object and the
static methods like MB.Show() calls the CreateWindow() of another calls which
is derived from NativeWindow. but with static methods one cant call the
createWindow and pass the Handle to it.
I'm fixed here. is deriving it from the form is a option or what
else are the possibilities i can do it.
please respond if anyone know about this,
thank you,
Harry
 
Harry,

Is that not a lot of work, a messagebox itself is nothing more than a
derived form where from the grip and the the controlbox are set to false,
the maximumsize and minimusize are set and some more of those things. So
when you derive it from form it is very easy to do.

And use than to show it with mymessagebox.showdialog (or whatever as a
method).

I hope this helps?

Cor

"Harry_Crow"
 
Back
Top