Thread: Resolve error in Windows Macro?

  1. #1
    Registered User
    Join Date
    Jan 2002
    Posts
    34

    Resolve error in Windows Macro?

    Hello,
    This is a windows .c program.

    The context:/*This is the windows function
    *for the main window. Etc.*/

    The error:Macro "Create windowA" used with only ten args.

    The error is indicated at the closing parentheses (),
    below the NULL statement.

    The Macro:// Now create the button.

    hwndButton = CreateWindow (
    "button", //Builtin button class.
    "Click Here",
    WS_CHILD | WS_VISIBLE | BS_PUSH
    BUTTON, 0, 0, cx, cy,

    hwnd, //Parent is this window.

    (HMENU) 1, //Control ID:1.

    ((LPCREATESTRUCT) lParam)-> hIn
    stance,
    NULL
    );

    return 0;
    break;

    }


    How do I resolve this problem?

    Thank you,

    Adock.

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Hmm, let me think...

    Is the C? I don't think so.

    Quzah.
    Hope is the first step on the road to disappointment.

  3. #3
    Code Goddess Prelude's Avatar
    Join Date
    Sep 2001
    Posts
    9,897
    Code:
    hwndButton = CreateWindow ( 
                 "button",
                 "Click Here", 
                 WS_CHILD | WS_VISIBLE | BS_PUSHBUTTON, 
                 0, 
                 0, 
                 cx, 
                 cy, 
                 hwnd, 
                 (HMENU) 1, 
                 ((LPCREATESTRUCT) lParam)-> hInstance, 
                 NULL 
                 );
    It looks okay to me, make sure your comments aren't messing anything up and that none of your arguments are cut off with a newline.

    p.s. This should really be in the Windows programming board.

    -Prelude
    My best code is written with the delete key.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Just starting Windows Programming, School me!
    By Shamino in forum Windows Programming
    Replies: 17
    Last Post: 02-22-2008, 08:14 AM
  2. how to make a windows application
    By crvenkapa in forum C++ Programming
    Replies: 3
    Last Post: 03-26-2007, 09:59 AM
  3. Question..
    By pode in forum Windows Programming
    Replies: 12
    Last Post: 12-19-2004, 07:05 PM
  4. IE 6 status bar
    By DavidP in forum Tech Board
    Replies: 15
    Last Post: 10-23-2002, 05:31 PM
  5. Manipulating the Windows Clipboard
    By Johno in forum Windows Programming
    Replies: 2
    Last Post: 10-01-2002, 09:37 AM