c++ - Creating Toolbox objects (e.g. Labels etc.) in code -
i'm new @ using microsoft visual studio, have knowledge c++ language. i'd create object can found in toolbox, such labels, button, etc., without putting them onto window hand.
how can it?
objects/controls labels , buttons special type of window, associated window class , window procedure. such, call createwindowex , supply second parameter, lpclassname, class name of object/control want create (eg. label use class name static
).
check out following tutorial complete example, using button class
to create button:
hwnd hwndbutton=createwindowex(null, "button", "ok", ws_tabstop|ws_visible|ws_child|bs_defpushbutton, 50, 220, 100, 24, hwnd, (hmenu)idc_main_button, getmodulehandle(null), null);`
Comments
Post a Comment