🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.ms.programmer
Article #1146

Re: Dialog Boxes

#1146
From: RAKESH TANDON
Date: Fri, 25 Jan 1991 15:50
29 lines
1588 bytes
In article <11395@darkstar.ucsc.edu>, hall@ucscb.ucsc.edu (60265000) writes:
> 
> Name: hall@ucscb.ucsc.edu
> 
> I was wondering if there was a way to make a dialog box the main
> window of a program and be able to minimize the dialog box into
> an icon.  I know it is possible if you make your own controls, but
> is it possible with a dialog resource script?
> 

Instead of doing a CreateWindow call do a CreateDialog call, This create
the Dialog box as the main window.

N.B.
Define your template in the resource file as normal but give it a CLASS,
You then have to Register that class and then call 
CreateDialog (hInst, <dialog template name>, 0, NULL) ;

You can define the icon, menu, window proc for the class just as you 
do for a normal window. You must set cbWndExtra to DLGWINDOWEXTRA in your
class structure.

If you get stuck I can email some sample code to help you out

-- 
Rakesh Kumar Tandon 	            : email   : rkt@bj.co.uk
Boldon James Limited	            : phone   : 0260 280465
Damian House, West Street           : fax     : 0260 298030
CONGLETON, Cheshire                 : UUCP    : ..!mcsun!ukc!pyrltd!bjcong!rkt
Technical Details
Message-ID: <1120@bjcong.bj.co.uk>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!uwm.edu!spool2.mu.edu!uunet!mcsun!ukc!pyrltd!bjcong!rkt
References: <11395@darkstar.ucsc.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!uwm.edu!spool2.mu.edu!uunet!mcsun!ukc!pyrltd!bjcong!rkt
From: rkt@bjcong.bj.co.uk (RAKESH TANDON)
Newsgroups: comp.windows.ms.programmer
Subject: Re: Dialog Boxes
Summary: CreateDialog
Message-ID: <1120@bjcong.bj.co.uk>
Date: 25 Jan 91 15:50:39 GMT
References: <11395@darkstar.ucsc.edu>
Organization: Boldon James Limited (Congleton, UK)
Lines: 29