|
-
February 25th, 2009, 06:19 PM
#1
Error creating an object based on a dialog declared in a .rc resource file
Hi All,
I'm trying to create a new dialog in my .rc resource file and then create a
C++ object using it. As far as I can tell, I'm doing it the same way that other
dialogs have been implemented in this large legacy VC++ version 2.0 project,
but I get
error C2065: 'WMM_DOOR_CONTROLS' : undeclared identifier
upon compiling the file that tries to create the object, from the following line:
WMMAuxIOSelectDial AuxIOCtrl (this, WMM_DOOR_CONTROLS);
As far as I can tell, the only place this identifier is declared is with the
resource in the resource file; that is the only place the other dialogs'
ids are found.
Obviously, there is a lot I don't know. Is there some kind of initial build
step that I need to run to process the .rc file so that the identifier will be
found in a generated file?
This line is in a file that hasn't had any other dialogs yet. Is there something
else that needs to be added?
Do I need a .dlg file, as well, for this resource?
This is non-MFC, using SDK calls only.
I've tried a lot of small stuff with which I don't want to belabor this post,
and I've done a lot of web searching, however I'm hoping there's something easy
that I don't know about that I can try, and I haven't thoroughly searched all
the MSDN and usenet posts, but I have put in about twelve hours of banging my
head against this and I'll continue to search while awaiting any replies.
Much thanks for any help you can give me.
Here is my resource declaration:
---------------------
Code:
WMM_DOOR_CONTROLS DIALOG DISCARDABLE 200, 10, 162, 138
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Door Controls"
FONT 8, "MS Sans Serif"
BEGIN
CONTROL "",-1,"Static",SS_BLACKFRAME | WS_GROUP,10,9,141,97
PUSHBUTTON "&Cancel",IDCANCEL,66,115,30,14
PUSHBUTTON "Door 1",WMM_IDB_SEL_RELAY1,20,18,122,14
PUSHBUTTON "Door 2",WMM_IDB_SEL_RELAY2,20,40,122,14
PUSHBUTTON "Door 3",WMM_IDB_SEL_RELAY3,20,62,122,14
PUSHBUTTON "Door 4",WMM_IDB_SEL_RELAY4,20,83,122,14
END
---------------------
Should I also post my WMMAuxIOSelectDial class code?
Best regards,
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|