well, OK, I guess I'll have to cope with writing all this by hand.

But I still don't understand how can I use DialogBox() to create a *window* (a.k.a. Form). You see, I don't need a modal *message box*, I need a usual window where I can place my own buttons and other controls, but which would be modal, so that I couldn't switch to the parent window. Can anybody give me some sample code or some link maybe?

Thanks for the reply!