What's wrong with this resource file?

This is a discussion on What's wrong with this resource file? within the Windows Programming forums, part of the Platform Specific Boards category; I'm trying to compile this application using Dev-C++ and the compiler coughs up when it tries to compile the resource ...

  1. #1
    Registered User -leech-'s Avatar
    Join Date
    Nov 2001
    Posts
    54

    What's wrong with this resource file?

    I'm trying to compile this application using Dev-C++ and the compiler coughs up when it tries to compile the resource file, saying there's a "parse error." The thing is that i can't find anything wrong with it:
    Code:
    #include "resource.h"
    #include <windows.h>
    
    IDI_ICON1               ICON    DISCARDABLE     "LEECH.ICO"
    
    
    IDD_DIALOG1 DIALOG DISCARDABLE  0, 0, 167, 59
    STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
    CAPTION "Resolution Selection"
    FONT 8, "Arial"
    BEGIN
        DEFPUSHBUTTON   "OK",IDOK,103,15,50,14,BS_FLAT
        PUSHBUTTON      "Cancel",IDCANCEL,103,33,50,14,BS_FLAT
        LTEXT           "Please select a resolution:",IDC_STATIC,6,5,84,9
        CONTROL         "640 x 480",IDC_640,"Button",BS_AUTORADIOBUTTON | 
                        BS_FLAT,18,17,61,11
        CONTROL         "800 x 600",IDC_800,"Button",BS_AUTORADIOBUTTON | 
                        BS_FLAT,18,30,61,11
        CONTROL         "1024 x 768",IDC_1024,"Button",BS_AUTORADIOBUTTON | 
                        BS_FLAT,18,43,61,11
    END
    Any ideas?

    edit: forgot to mention, the compiler says the error is on line 14 (LTEXT)...
    Last edited by -leech-; 09-13-2002 at 12:40 PM.
    Not yet, have to think of one...

  2. #2
    erstwhile
    Join Date
    Jan 2002
    Posts
    2,227
    #define IDC_STATIC -1

  3. #3
    Registered User
    Join Date
    Aug 2002
    Posts
    57
    I've had the same problem. Define IDC_STATIC. It has to be a constant integer that equals to -1(because you never actually use it).
    "A Programmer being told to 'go to' hell sees the 'go to' part of the sentence as the worst part." - Master Foto

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. File Writing Problem
    By polskash in forum C Programming
    Replies: 3
    Last Post: 02-13-2009, 10:47 AM
  2. opening empty file causes access violation
    By trevordunstan in forum C Programming
    Replies: 10
    Last Post: 10-22-2008, 12:19 AM
  3. Dikumud
    By maxorator in forum C++ Programming
    Replies: 1
    Last Post: 10-01-2005, 07:39 AM
  4. archive format
    By Nor in forum A Brief History of Cprogramming.com
    Replies: 0
    Last Post: 08-05-2003, 08:01 PM
  5. menu resource file
    By satriani in forum Windows Programming
    Replies: 5
    Last Post: 06-08-2002, 11:52 PM

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