|
-
Jan 3rd, 2003, 12:12 AM
#1
Thread Starter
Hyperactive Member
STATIC class
What library should I include for this, because windows.h, stdlib.h, and commctrl.h aren't cutting it. Thanks in advance.
Code:
HWND CreateLabel(char caption[], char classname[], int x, int y, int height, int width)
{
HWND hwndButton;
hwndButton = CreateWindow(
STATIC, // predefined class
caption, // button text
WS_VISIBLE | WS_CHILD | SS_SIMPLE, // styles
x, // starting x position
y, // starting y position
height, // button width
width, // button height
hwnd, // parent window
NULL, // No menu
(HINSTANCE) GetWindowLong(hwnd, GWL_HINSTANCE),
NULL); // pointer not needed
return hwndButton;
}
-
Jan 3rd, 2003, 04:43 AM
#2
Monday Morning Lunatic
It's a string, so it needs to be in quotes.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jan 3rd, 2003, 06:57 AM
#3
Hyperactive Member
Classnames are just strings. Some have macro for them, include in commctrl.h.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|