Click here to Skip to main content
16,007,885 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralOpening Word Pin
29-Nov-01 8:01
suss29-Nov-01 8:01 
GeneralRe: Opening Word Pin
Bill Wilson29-Nov-01 8:35
Bill Wilson29-Nov-01 8:35 
GeneralRe: Opening Word Pin
Michael Dunn29-Nov-01 8:47
sitebuilderMichael Dunn29-Nov-01 8:47 
GeneralODBC and .txt files Pin
Stanislav29-Nov-01 7:14
Stanislav29-Nov-01 7:14 
GeneralRe: ODBC and .txt files Pin
Nish Nishant29-Nov-01 16:27
sitebuilderNish Nishant29-Nov-01 16:27 
Generalopen a document Pin
Monica29-Nov-01 7:04
Monica29-Nov-01 7:04 
GeneralRe: open a document Pin
Bill Wilson29-Nov-01 7:32
Bill Wilson29-Nov-01 7:32 
GeneralAfxResourceHandle is NULL Pin
Bill Wilson29-Nov-01 6:49
Bill Wilson29-Nov-01 6:49 
I have a com server application (.EXE). It was created using ATL, with MFC support. Following instructions from MSDN (Q181505
PRB: ATL COM AppWizard Doesn't Offer MFC Support for .EXE )I added #include <afxdisp.h> to my stdafx.h and changed #include <winres.h> to #include <afxres.h> in the .rc file as recommended.

All is well except that AfxResourceHandle seems to be NULL. This manifests itself when CDatabase or CRecordset tries to throw CDBException. In building the exception it attempts a LoadString which gets an assertion due to AfxResourceHandle being null.

Can any help me out here? I'm pretty sure AfxResourceHandle never got assigned, probably because its an ATL project. Is there something else I need to do?

I've seen two differnt MSDN articles on the subject and they don't agree!) The other one is
Q173974 HOWTO: Add MFC Support to an ATL Project.

Thanks for the help,
Bill
GeneralRe: AfxResourceHandle is NULL Pin
Michael Dunn29-Nov-01 7:00
sitebuilderMichael Dunn29-Nov-01 7:00 
GeneralRe: AfxResourceHandle is NULL Pin
Bill Wilson29-Nov-01 8:30
Bill Wilson29-Nov-01 8:30 
GeneralRe: AfxResourceHandle is NULL OOPS not fixed after all Pin
Bill Wilson29-Nov-01 10:11
Bill Wilson29-Nov-01 10:11 
GeneralNumbering edit control Pin
28-Nov-01 20:36
suss28-Nov-01 20:36 
GeneralNetwork problems in Win2000 Pin
v_krishnan28-Nov-01 20:06
v_krishnan28-Nov-01 20:06 
GeneralRe: Network problems in Win2000 Pin
Chambers29-Nov-01 9:37
Chambers29-Nov-01 9:37 
GeneralGet Audio timecode and play wav directly Pin
chen28-Nov-01 19:50
chen28-Nov-01 19:50 
GeneralXP themes Pin
28-Nov-01 19:46
suss28-Nov-01 19:46 
Generaldisplaying tooltips Pin
28-Nov-01 18:28
suss28-Nov-01 18:28 
QuestionDo i actually need a DocTemplate? Pin
foobat28-Nov-01 17:32
foobat28-Nov-01 17:32 
AnswerRe: Do i actually need a DocTemplate? Pin
Chambers29-Nov-01 8:28
Chambers29-Nov-01 8:28 
QuestionHas anyone had DevStudio lock up when stepping but not when running a prog? Pin
foobat28-Nov-01 16:37
foobat28-Nov-01 16:37 
AnswerRe: Has anyone had DevStudio lock up when stepping but not when running a prog? Pin
Mike Nordell28-Nov-01 16:53
Mike Nordell28-Nov-01 16:53 
GeneralRe: Has anyone had DevStudio lock up when stepping but not when running a prog? Pin
foobat28-Nov-01 17:05
foobat28-Nov-01 17:05 
AnswerRe: Try to use TRACE macro Pin
Masaaki Onishi28-Nov-01 17:21
Masaaki Onishi28-Nov-01 17:21 
GeneralRe: Try to use TRACE macro Pin
foobat28-Nov-01 17:37
foobat28-Nov-01 17:37 
GeneralColour to Grayscale Pin
PJ Arends28-Nov-01 15:53
professionalPJ Arends28-Nov-01 15:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.