Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Buttons on windows

Status
Not open for further replies.

ALEXPROG

Programmer
Aug 24, 2000
12
IL
How can I create a button or any other control on a regular window? The controls are suited for dialog boxes, and have several problems with windows. Even in the MSDN, they write that you should use the controls in dialog boxes.
 
Alex,

See CreateWindow() and CreateWindowEx() if you are using MFC CWnd::Create()

Hope this helps
-pete
 
palbano,

I can create the button in that way, but the button behaves strange. For example, the button doesn't show up before I click on "him" (on the area in which he supposed to be).
And in the MSDN, they write that "good" behavior of a button in a window isn't garanteed.
 
alex, did you solve your problem ? i'm looking for the same info - as far as i went i didn't get much !!!!
i can create the button, i see the button, but it only reacts once in a while to user's click (actually, once (but not the 1st time) and then no more)
i'm trying to attach some kind of a "control container" (ah ah ah haven't found yet which class is more suitable to handle that !!!) to my window, but i'll be stuck very soon :-(

can someone help ? pliz ?
 
hey ! i found out :)
msdn library -> windows ce doc -> user interface services -> creating controls
This section explains how to add window, common, and Windows CE–specific controls to windows and dialog boxes. It also explains how to handle control notification messages. The window controls discussed here include buttons, combo boxes, edit controls, list boxes, scroll bars, and static controls.(...)Controls are most often placed within dialog boxes, but they can also be placed directly on the surface of a normal window client area. (...)
s-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top