Hello everybody,

I have made a little dialog (on a resource file) and now Im lost on how to call it from my app. :( ... I have found on win32 ref a thing called CreateDialog (and CreateDialogIndirect) but that seem to be macros on C/C++ only.

I even downloaded some header (winuser.h) but there are no usefull info in it too. :\

Only thing I foound, that is usefull, is that CreateDialog* functions (MACROS, really) are based on CreateWindowEx API ( maybe CreateWindow too???:\ ) ... anyway, how does it use a resource then? I didn't find mentions anywhere on CreateWindowEx ref!

I have attached my resource file in this post (wich I plan to LINK to my app in compiling time). I plan to use the dialog you'll see in that file, as my main and ONLY window, in the application (null parent is ok, isn't it? :).

I have not attached source, since it seems unimportant to me, in sight that I cant show the dialog yet.

TIA! ;)

Ps: why the heck are attachements blocked by extensions??? >:( ... whoever download the file, change it to ".res"... :-?
Posted on 2002-11-21 09:54:45 by wicr0s0ft
There are a lot examples for that in examples folder in your MASM32 directory or read Iczelions tutorials. :)

Hint: search for DialogBoxParam
Posted on 2002-11-21 10:18:52 by bazik

Bazik is correct.
The CreateDialog macro creates a modeless dialog box from a dialog box template resource. The CreateDialog macro uses the CreateDialogParam function.

The CreateDialogIndirect macro creates a modeless dialog box from a dialog box template in memory. The CreateDialogIndirect macro uses the CreateDialogIndirectParam function.

So look for into msdn for CreateDialogParam and CreateDialogIndirectParam.
Posted on 2002-11-21 21:48:29 by roticv
Hello, :)

I got my little window shiny and working, but a few things were/are a problem for me now.

Fisrt is that I kept playing with those style values until I discover which of them were what I had in my mind... as this took some valuable time, I thought next time I should be just consulting some very detailed reference on those. Do you have or know where can I find one? :) (please, do not tell me to look on the win32api. It does not says much!)

Second: can I show a minimize button on my dialog? Is it just style cuttie or maybe Ill have to draw that if I want?? :\

Ill paste the main part of my .rc here just in case. It is not that bloat anyway.

100 DIALOGEX 0, 0, 150, 190
CAPTION "Program v0.1a"
Posted on 2002-11-24 23:12:44 by wicr0s0ft