Menu

resource syntax error

Anubis208
2007-07-26
2012-09-26
  • Anubis208

    Anubis208 - 2007-07-26

    I am using theForger's win api tutorial and am on the part about dialog boxes. I am using a c++ project. I get the following error when ai try to compile: Compiler: Default compiler
    Building Makefile: "C:\mycppstuff\menu3\Makefile.win"
    Executing make...
    make.exe -f "C:\mycppstuff\menu3\Makefile.win" all
    windres.exe -i Project1_private.rc --input-format=rc -o Project1_private.res -O coff

    windres.exe: resource.rc:22: syntax error

    make.exe: *** [Project1_private.res] Error 1

    Execution terminated

    windows XP devcPP 4.9.9.2

    code:

    include "resource.h"

    IDR_MYMENU MENU
    BEGIN
    POPUP "&File"
    BEGIN
    MENUITEM "E&xit", ID_FILE_EXIT
    END
    POPUP "&Stuff"
    BEGIN
    MENUITEM "&Go", ID_STUFF_GO
    MENUITEM "G&o somewhere else", 0, GRAYED
    END
    POPUP "&Help"
    BEGIN
    MENUITEM "&About", ID_HELP_ABOUT
    END
    END

    IDI_MYICON ICON "Smile.ico"

    IDD_ABOUT DIALOG DISCARDABLE 0, 0, 239, 66
    STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
    CAPTION "My about box....."
    FONT 8, "MS Sans Serif"
    BEGIN
    DEFPUSHBUTTON "OK", IDOK, 174, 18, 50, 14
    PUSHBUTTON "Cancel", IDCANCEL, 174, 35, 50, 14
    GROUPBOX "About this program....", IDC_STATIC, 7, 7, 225, 52
    CTEXT "An example program showing how to display Dialog Boxes/r/n/r/nby theForger",
    IDC_STATIC, 16, 18, 144, 33
    END

     
    • Anubis208

      Anubis208 - 2007-08-12

      that worked thanks.

       
    • Nobody/Anonymous

      include "windows.h"

       
    • Anubis208

      Anubis208 - 2007-08-11

      That didn't work, I got the same error.

       
    • Nobody/Anonymous

      Include

      if !defined (_WINDOWS)

      #define _WINDOWS
      

      endif

      If that fail, include

      ifndef IDC_STATIC

      define IDC_STATIC (-1)

      endif

      Old newbie

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.