Click here to Skip to main content
15,906,574 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: C++ interview quetions? Pin
Joe Woodbury3-Oct-06 10:02
professionalJoe Woodbury3-Oct-06 10:02 
GeneralRe: C++ interview quetions? Pin
ThatsAlok3-Oct-06 18:43
ThatsAlok3-Oct-06 18:43 
GeneralRe: C++ interview quetions? Pin
Christian Graus3-Oct-06 11:36
protectorChristian Graus3-Oct-06 11:36 
GeneralRe: C++ interview quetions? Pin
led mike4-Oct-06 4:59
led mike4-Oct-06 4:59 
GeneralRe: C++ interview quetions? Pin
ThatsAlok3-Oct-06 18:42
ThatsAlok3-Oct-06 18:42 
AnswerRe: C++ interview quetions? Pin
Christian Graus3-Oct-06 11:35
protectorChristian Graus3-Oct-06 11:35 
GeneralRe: C++ interview quetions? Pin
Jun Du3-Oct-06 12:29
Jun Du3-Oct-06 12:29 
QuestionMethods in linking C source code with C++ code Pin
searcher083-Oct-06 7:20
searcher083-Oct-06 7:20 
I have developed the GUI using Visual C++ and need to incorporate the functions into the application. The functions are written in C code.

I have been trying to link the two codes together but things are not working fine.

Approach I took:
1. Inserted the C source code project into my GUI application workspace.

2. Make the GUI application dependent on the C source code project.

3. Included the header files from the C source code project and the compilation was fine.

4. Transfer the functions in main program of the C source code to the GUI Dialog class. No problem in terms of compiling though I am not too sure whether this is correct.
Use the following method for the declarations for the C functions in the header file.
afx_msg void decode(void);
afx_msg void Configure(void);
For the function in the cpp file, I used the following method for the first function to be called. The remaining functions remain as C types function headers. If I remove the C++ function declaration, there will be errors as the rest of the C functions could not be recognized.

void Dialogc::decode(void);
void Configure(void);

5. No problem on compiling. However, during the linking up, there are some extern variables in the image processing files that need referencing to. They are declared in the Dialog cpp file. That is the reason for the "unresolved external symbol _img" and the strings of other error message.
I have tried including the Dialogc.h in the source file of the image processing file and they could not recognize the class terms i.e. more error occurred.

Thanks.

lost in time
AnswerRe: Methods in linking C source code with C++ code Pin
Waldermort3-Oct-06 9:05
Waldermort3-Oct-06 9:05 
QuestionRe: Winsock2 problem Pin
searcher083-Oct-06 17:49
searcher083-Oct-06 17:49 
AnswerRe: Winsock2 problem Pin
Hamid_RT3-Oct-06 18:48
Hamid_RT3-Oct-06 18:48 
QuestionOne class with Multiple IDDs (is this possible) Pin
kitty53-Oct-06 6:35
kitty53-Oct-06 6:35 
AnswerRe: One class with Multiple IDDs (is this possible) Pin
cje3-Oct-06 10:30
cje3-Oct-06 10:30 
AnswerRe: One class with Multiple IDDs (is this possible) Pin
David Crow3-Oct-06 11:14
David Crow3-Oct-06 11:14 
QuestionWorking with colors Pin
shoelace3-Oct-06 5:32
shoelace3-Oct-06 5:32 
AnswerRe: Working with colors Pin
Chris Losinger3-Oct-06 8:04
professionalChris Losinger3-Oct-06 8:04 
QuestionHow to get en exe default icon Pin
Kharfax3-Oct-06 4:45
Kharfax3-Oct-06 4:45 
QuestionRe: How to get en exe default icon Pin
David Crow3-Oct-06 4:48
David Crow3-Oct-06 4:48 
AnswerRe: How to get en exe default icon Pin
Kharfax3-Oct-06 4:53
Kharfax3-Oct-06 4:53 
AnswerRe: How to get en exe default icon, more problems :S Pin
Kharfax3-Oct-06 5:34
Kharfax3-Oct-06 5:34 
QuestionRe: How to get en exe default icon, more problems :S Pin
David Crow3-Oct-06 5:54
David Crow3-Oct-06 5:54 
AnswerRe: How to get en exe default icon, more problems :S Pin
Kharfax3-Oct-06 6:18
Kharfax3-Oct-06 6:18 
AnswerRe: How to get en exe default icon, more problems Pin
James R. Twine3-Oct-06 6:44
James R. Twine3-Oct-06 6:44 
GeneralRe: How to get en exe default icon, more problems Pin
toxcct3-Oct-06 6:59
toxcct3-Oct-06 6:59 
GeneralRe: How to get en exe default icon, more problems :S Pin
David Crow3-Oct-06 6:59
David Crow3-Oct-06 6:59 

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.