Visual C++ NOOB - Working with MFC DLL linking option in the project setting

Alright, must confess that I am indeed a NOOB when it comes to Visual C++ despite the fact that I learned C++ first and started to work with this language initially in my current work place (of 10 years++).

Had a chance again to work with C++ after so many years away from it, which I'm looking forward to because C++ is really the language that I'd really want to master.  So the current project is giving me quite a lot of headache considering it is an upgrade from the old Visual Studio 6.0 to the not-so-latest Visual Studio 2010, I would expect a lot of hurdles to overcome.  Thankfully my genius colleague who has previously worked on the upgrading provided me with his sample to look at, plus referring back to the old project in VS6, I finally able to get it up and running (without crashing, phew).

So here's what I've learned from this task.

1. Use of MFC setting
So the use of MFC setting has to be consistent throughout all projects within the solution.  If the main project is linked dynamically, then all dependent project has to be done so as well.  Otherwise there would be "unresolved external" issue throws at function that uses MFC classes or functions.

2. Wide Character
This is such a stranger to me last time, for I didn't know much about the differences in wide character and normal ANSI character.  After doing other projects, I've finally able to understand what are they.  Yet, in VS2010, the setting of the project: UNICODE, MULTIBYTE, or the standard ASCII would result in different handling of the wide character string.  So, this is something that I need to be careful about and to take note in future development.  Well, considering the trend now is multilingual, better start cracking to learn it.

3. External Dependencies
Again another thing that's so foreign to me last time, and again it is something after doing other project in other languages that I've finally able to at least grab hold of the concept.  In VS2010 for C++, there are a bunch of settings for external dependencies: include, lib, src, reference (all under the VC++ Directories setting), and then Additional Dependancies under Linker -> Input settings.  These are all so easily done in order language, but in C++, man that's...  Harder...

Alright, that's all to remember for now...

Comments

Popular posts from this blog

Yahoo! Messenger voice call & video call disabled, why?

Sport's Injuries - Treatment for bruises

Web Development: Disable, Validate, & Enable Buttons