473,320 Members | 1,887 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Can I use vs2005 to write a VC6 MFC program?

Tau
Because vc8 uses MFC80.dll, and many PCs don't have these libraries...
So I wonder if I can use vs2005's IDE to write a vc6 program? I mean
just using mfc42.dll, etc...to make it runnable on other machines.

Thanks in advance.

Jan 16 '06 #1
7 3223
Tau wrote:
Because vc8 uses MFC80.dll, and many PCs don't have these libraries...
So I wonder if I can use vs2005's IDE to write a vc6 program? I mean
just using mfc42.dll, etc...to make it runnable on other machines.


If you work hard enough at it, maybe. Practially speaking no. You can, of
course, simply distribute the MFC8 DLLs along with your program.

-cd
Jan 16 '06 #2
Tau wrote:
Because vc8 uses MFC80.dll, and many PCs don't have these libraries...
So I wonder if I can use vs2005's IDE to write a vc6 program? I mean
just using mfc42.dll, etc...to make it runnable on other machines.

Thanks in advance.


It is possible to certain extent. Microsoft keeps LIB format pretty much
compatible across generations of VC++ and I have successfully used
MSVCRT.DLL and MFC42.DLL with VS2003 and VS2005 on smaller utilities,
then CArray broke my code :)

Anyway, the method is:

1. Get VC6 libraries (e.g. from Windows 2003 DDK available for nominal
S&H fee from MS)

2. Disable "Buffer security check" in project property page -> C++ ->
Code Generation

3. Add path to your VC6 include files in C++ ->General -> Additional
Include Directories (e.g. C:\WINDDK\3790\inc\mfc42)

4. Add path to your VC6 libraries in Linker -> General -> Additional
Library Directories (e.g. C:\WINDDK\3790\lib\w2k\i386)

Good luck
Roman Ziak
Jan 16 '06 #3
Tau wrote:
Because vc8 uses MFC80.dll, and many PCs don't have these libraries...
So I wonder if I can use vs2005's IDE to write a vc6 program? I mean
just using mfc42.dll, etc...to make it runnable on other machines.

FYI, MFC42.dll is *NOT* guaranteed to be available on all machines either
(it has never been an official part of the OS), so you need to distribute it
anyway. Considering things this way, it is as simpleto switch to the current
version.

Arnaud
MVP - VC
Jan 16 '06 #4
Tau
Ok. Your method does work! :-)

but i met another problem that i got a link error:

error LNK2019: unresolved external symbol __ftol2_sse referenced in
function...

i went through the function code, and found that this problem is caused
by float-int conversion!
how can i get rid of this error? Thanks!

Jan 16 '06 #5
Arnaud Debaene wrote:
Tau wrote:
Because vc8 uses MFC80.dll, and many PCs don't have these libraries...
So I wonder if I can use vs2005's IDE to write a vc6 program? I mean
just using mfc42.dll, etc...to make it runnable on other machines.

FYI, MFC42.dll is *NOT* guaranteed to be available on all machines either
(it has never been an official part of the OS), so you need to distribute it
anyway. Considering things this way, it is as simpleto switch to the current
version.

Arnaud
MVP - VC


This may be true for early version Win95, but I actually looked through
several different machines and it is always there including Win95 w/
Service Pack.
Jan 16 '06 #6
Roman wrote:
This may be true for early version Win95, but I actually looked
through several different machines and it is always there including
Win95 w/ Service Pack.


Perhaps, but it has never been guranteed by MS, so you're on your own when a
client will call because it can't run your soft because of a missing DLL.

Arnaud
MVP - VC
Jan 16 '06 #7
Tau wrote:
Ok. Your method does work! :-)

but i met another problem that i got a link error:

error LNK2019: unresolved external symbol __ftol2_sse referenced in
function...

i went through the function code, and found that this problem is caused
by float-int conversion!
how can i get rid of this error? Thanks!


Sorry, cannot help you, never had that problem. You could probably find
what is the appropriate in MSVCRT.DLL and write __declspec(naked)
wrapper with a jump.
Jan 18 '06 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: DaVBGuy | last post by:
I'm currently using VB 6 for windows based apps. Should I make the jump to VS.2003 now, or should I wait till (the final) VS.2005 release comes out later this year. If I have not started...
2
by: -DG- | last post by:
No reply on my previous query, so I'll post this again. I've done a bit more research in the interim. I'm trying to find an easy way to port code from the older VS2003 format to the format used...
7
by: Greg P | last post by:
I know this is a long post, please bear with me. I have been working on this all weekend to no avail although I have done a good amount of research (see most pertinent links that I've looked at...
0
by: GT | last post by:
This question has been posted before, but without any response so therefore I'm trying once more. I'm trying to embed .resource files into a Windows application in VS2005, and then compile and...
2
by: fineman | last post by:
Hi all, I want to get a 64bit(8 bytes) Encrypt result use DES class in the VS2005. Though I encrypt data is 64bit(8 bytes), but DES return encrypt result that always is 128bit(16 bytes), I don't...
3
by: Thomas | last post by:
Hi, I have written a simple console program in VS2005 and it should run on computers that dosn't have .NET (not 1.1 and not 2.0). I think it depends on the headerfiles? I have exculded the...
4
by: =?Utf-8?B?TmFkYXYgUG9wcGxld2VsbA==?= | last post by:
Hi everybody, I've got two questions about using the EnableSession property with an ASP.NET WebService: First Question: I'm trying to create a web service with EnableSession=true. I can't...
4
by: Bit Byte | last post by:
I'm having problem compiling one of my projects with VS2005. The problems arise with VS2005 (apparent?) inability to compile log4cpp. Has anyone succesfully compiled log4cpp using VS2005? Here...
6
by: =?Utf-8?B?SGFycnkgVg==?= | last post by:
I wrote a C# Windows app using VS2003 to read selected text files and write the data to 3 tables in an Access database. After "upgrading" to VS2005, I tried to add a feature and rebuild - what a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.