Results 1 to 3 of 3

Thread: STATIC class

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 1999
    Location
    Cleveland, Ohio
    Posts
    263

    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;
    }

  2. #2
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    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

  3. #3
    Hyperactive Member made_of_asp's Avatar
    Join Date
    Jul 2001
    Location
    123 Fake Street
    Posts
    394
    Classnames are just strings. Some have macro for them, include in commctrl.h.

    Code:
    "static"
    VS.NET 2003

    Need to email me?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width