sub-menu separator

This is a discussion on sub-menu separator within the Windows Programming forums, part of the Platform Specific Boards category; hey, i have a sub-menu in my program which has a new, open, save, cut, copy, and paste button. however, ...

  1. #1
    Shibby willc0de4food's Avatar
    Join Date
    Mar 2005
    Location
    MI
    Posts
    378

    sub-menu separator

    hey, i have a sub-menu in my program which has a new, open, save, cut, copy, and paste button. however, i'd like to have a space between the first 3 and the last 3. how can i do this? thanks
    Registered Linux User #380033. Be counted: http://counter.li.org

  2. #2
    Registered User Joelito's Avatar
    Join Date
    Mar 2005
    Location
    Tijuana, BC, México
    Posts
    308
    MF_SEPARATOR.
    Code:
    AppendMenu(hMenu, MF_SEPARATOR, someID, NULL);

  3. #3
    Shibby willc0de4food's Avatar
    Join Date
    Mar 2005
    Location
    MI
    Posts
    378
    and i would place that where in my code? because it doesn't work here:
    Code:
    tbb[2].iBitmap = STD_FILESAVE;
    tbb[2].fsState = TBSTATE_ENABLED;
    tbb[2].fsStyle = TBSTYLE_BUTTON;
    tbb[2].idCommand = ID_FILE_SAVEAS;
                           
    AppendMenu(hTool, MF_SEPARATOR, someID, NULL);
                           
    tbb[3].iBitmap = STD_COPY;
    tbb[3].fsState = TBSTATE_ENABLED;
    tbb[3].fsStyle = TBSTYLE_BUTTON;
    tbb[3].idCommand = ID_EDIT_COPY;
    i get this error:
    warning: passing arg 1 of `AppendMenuA' from incompatible pointer type
    Registered Linux User #380033. Be counted: http://counter.li.org

  4. #4
    Registered User Joelito's Avatar
    Join Date
    Mar 2005
    Location
    Tijuana, BC, México
    Posts
    308
    ow! You mean in Toolbar, that you didn't mention that you were working with toolbars
    Well... try TBSTYLE_SEP

  5. #5
    Shibby willc0de4food's Avatar
    Join Date
    Mar 2005
    Location
    MI
    Posts
    378
    sweet thanks.

    haha, yea..i can see how you'd think i was referring to menu's rather than toolbars. usually i just use SEPERATOR though for those..
    Registered Linux User #380033. Be counted: http://counter.li.org

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Checking array for string
    By Ayreon in forum C Programming
    Replies: 87
    Last Post: 03-09-2009, 03:25 PM
  2. Replies: 2
    Last Post: 03-05-2009, 09:25 AM
  3. Another syntax error
    By caldeira in forum C Programming
    Replies: 31
    Last Post: 09-05-2008, 01:01 AM
  4. Constructive Feed Back (Java Program)
    By xddxogm3 in forum Tech Board
    Replies: 12
    Last Post: 10-10-2004, 03:41 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21