Menu problem

This is a discussion on Menu problem within the Windows Programming forums, part of the Platform Specific Boards category; Im trying to add a menu to my simple text-editor, The contents of the .rc file is: Code: #include "EEdit_res.h" ...

  1. #1
    Registered User morbuz's Avatar
    Join Date
    Aug 2001
    Posts
    35

    Angry Menu problem

    Im trying to add a menu to my simple text-editor,

    The contents of the .rc file is:
    Code:
    #include "EEdit_res.h"
    
    MainMenu MENU DISCARDABLE
    {
    POPUP "FILE"
    	{
    	MENUITEM "Open", MENU_FILE_ID_OPEN
    	}
    }
    and the conetents of the EEdit_res.h file is:
    Code:
    #define MENU_FILE_ID_OPEN 1000
    When i try to compile I get the Error: "EEdit_res.h(1) : fatal error RC1004: unexpected end of file found"

    What is wrong?
    [Signature here. (Remove this!)]

  2. #2
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,789
    >>#define MENU_FILE_ID_OPEN 1000

    Are there any charectors after "1000"?

    After "1000" just press enter once so the cursor goes down a line.

    See if that works.

  3. #3
    Registered User morbuz's Avatar
    Join Date
    Aug 2001
    Posts
    35
    Omg! That worked!
    The world of (Visual) C++ is strange!
    [Signature here. (Remove this!)]

  4. #4
    Registered User morbuz's Avatar
    Join Date
    Aug 2001
    Posts
    35

    Question Horizontal line

    One more thing... how can make a horizontal line in my menu?
    [Signature here. (Remove this!)]

  5. #5
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,789
    >>One more thing... how can make a horizontal line in my menu?

    You need to flag it as a SEPERATOR

    For example..
    Code:
    #include "EEdit_res.h"
    
    MainMenu MENU DISCARDABLE
    {
    POPUP "FILE"
    	{
    	MENUITEM "Open", MENU_FILE_ID_OPEN
                    MENUITEM SEPARATOR
                    MENUITEM "Close", MENU_FILE_ID_CLOSE
    	}
    }

  6. #6
    Registered User morbuz's Avatar
    Join Date
    Aug 2001
    Posts
    35

    Smile

    Thx again!
    [Signature here. (Remove this!)]

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. A question related to strcmp
    By meili100 in forum C++ Programming
    Replies: 6
    Last Post: 07-07-2007, 02:51 PM
  2. Simple Menu Problem
    By DanC in forum C++ Programming
    Replies: 4
    Last Post: 03-15-2006, 12:33 PM
  3. Problem with Mouse Over Menu!!! HELP!!!
    By SweeLeen in forum C++ Programming
    Replies: 3
    Last Post: 02-09-2006, 01:10 AM
  4. Window - Menu problem...
    By FromHolland in forum Windows Programming
    Replies: 1
    Last Post: 02-26-2004, 02:49 PM
  5. MDI and MENU Problem
    By Marc in forum Windows Programming
    Replies: 3
    Last Post: 02-21-2004, 05:59 PM

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