home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.ms-windows.programmer.misc
- From: chris@chrism.demon.co.uk (Chris Marriott)
- Path: sparky!uunet!pipex!demon!chrism.demon.co.uk!chris
- Subject: Re: Create buttons dynamically, how?
- Distribution: world
- References: <PS.92Dec14233706@kielo.uta.fi>
- Organization: None
- Reply-To: chris@chrism.demon.co.uk
- X-Mailer: Simple NEWS 1.90 (ka9q DIS 1.19)
- Lines: 28
- Date: Tue, 15 Dec 1992 14:24:38 +0000
- Message-ID: <724429478snz@chrism.demon.co.uk>
- Sender: usenet@demon.co.uk
-
- In article <PS.92Dec14233706@kielo.uta.fi> ps@uta.fi writes:
-
- >How can you create buttons dynamically? That is, how the application
- >can decide during run-time the number and the positions of the buttons
- >it wants to create? All the demonstration programs (BC++/AF/OWL) seem
- >to have a fixed number of buttons. Some other button-like control
- >could serve as well, as long I can create and destroy them
- >dynamically.
- >--
- >Pertti Suomela
- >
- >Internet: ps@uta.fi
- >X.400: G=Pertti S=Suomela O=uta ADMD=fumail C=fi
- >
-
- Just use the "CreateWindow" function, exactly as you would for any
- other window, using the pre-defined "BUTTON" window class. All the
- standard Windows controls can be dynamically created in this way -
- look in the documentation of the "CreateWindow" function to find
- the names of the pre-defined classes.
- --
- --------------------------------------------------------------------------
- | Chris Marriott | chris@chrism.demon.co.uk |
- | Warrington, UK | BIX: cmarriott |
- | (Still awaiting inspiration | CIX: cmarriott |
- | for a witty .sig .... ) | CompuServe: 100113,1140 |
- --------------------------------------------------------------------------
-
-