Export MFC App advice

OK, so I've finished my little MFC-based
application and its time to export it to
throngs of eager users!  This is my first MFC/C++ project, so I'm trying to
figure out how to do things...

My app is pretty simple, I do not use
any active X stuff, nor COM, nor ATL, etc.  Its just MFC and C++.  Hence, from
something I read somewhere, I guessed that it needs 2 DLLs - namely, MFC42.DLL
and MSVCRT.DLL.  I ran depends.exe on it
and it showed these 2, and also showed
3 others which I think are pretty clearly from the windows OS itself, and
so I don't think I need to worry about them - they would be on any 32bit windows machine (I would like my app to
run on 98,NT,2000, maybe 95?)

OK.  As I've been learning stuff in the
windows/MFC world, I've kinda ignored
learning about DLLs cause I always said
that "I'll just statically link my app".
Now I discover that VC++ "standard
edition" doesn't support static linking
of the MFC lib; I need to upgrade to the
professional edition for that.  Arg.
By the way, why did MS set it up this
way?  In my mind statically linking is
a "simple basic" thing thta I thought
would be available everywhere -- why put
it in the "fancier" version of VC++?
Anyway... I'm getting to my question(s),
please bear with my ramblings....

So, looks like I have two choices:
A) upgrade to Prof edition, ask for
   static linking, and be done with it.
B) learn how to export those 2 DLLs and
   "register" them with the target

My problem is that I have no clue how to
export DLLs and register them -- I think
the logic is that my installer program
needs to check the target machine, and if there's no DLL or an older version,
then I need to stick the DLL on the target machine and then I have to incant
some mysterious "registration" command
to tell the OS its there.  Is that about

My current plan to actually do the export and the setup/install at the
target is based on using a little
product called "INF-Tool" from
Inner-Smile.com.  anyone used it?  Is it
going to help me check and register my

I would appreaciate any suggestions or
corrections to my understanding of all
this!  Thanks in advance!!

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
tullheadAuthor Commented:
Thanks for that reference Chensu, but
I need a little more help.  That article
still doesn't give the "how to".  It
says thinks like "you should redistribute and register mfc42.dll".
OK, but HOW?!

How do I check for a DLL at a target
machine and then how do I install and
register one if its needed there?
The following articles tell you how to do it.

Copying Files

Replacing DLLs in Memory

If you use some installation programs such as InstallShield, you don't have to do it yourself.
tullheadAuthor Commented:
My latest status:

Making a setup program for a small MFC-
based App.  I need to export mfc42.dll
and msvcrt.dll.  But it seems that I
only need to "register" mfc42.dll on
the target machine, and NOT msvcrt.dll.

I conclude this because when I tried to
register msvcrt.dll, I got an error,
something like "RegisterDllServer not
found for msvcrt.dll".

Amazingly, the article on
"Redistributing Microsoft Visual C++ 6.0 Applications" is unclear on this.

Can someone (chensu?) just confirm that I am right about this?
Don't register it. COM objects need to be registered. You need to only copy these DLLs.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.