473,383 Members | 2,005 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,383 software developers and data experts.

VC++ 2005 migration problem

hi, i have 1 MFC project which is written using VC++2003 but i need to
migrate to VC++2005. The program (VC++2003) is working fine. but there

is erros occur when running in VC++2005, and i just able to figure out
that the problem was come from the following code.
# ifdef WIN32
# if defined(MPSC_EXPORT)
# define MPSC_API __declspec( dllexport )
# elif defined(MPSC_IMPORT)
# define MPSC_API __declspec( dllimport )
# else /* for static libraries */
# define MPSC_API
# endif
# else /* !MD_WIN32 */
# define MPSC_API
# endif
would any one can tell me why this coding will be the problem for my
program?
thanks

Jul 20 '06 #1
3 1564
>hi, i have 1 MFC project which is written using VC++2003 but i need to
>migrate to VC++2005. The program (VC++2003) is working fine. but there
is erros occur when running in VC++2005, and i just able to figure out
that the problem was come from the following code.
# ifdef WIN32
# if defined(MPSC_EXPORT)
# define MPSC_API __declspec( dllexport )
# elif defined(MPSC_IMPORT)
# define MPSC_API __declspec( dllimport )
# else /* for static libraries */
# define MPSC_API
# endif
# else /* !MD_WIN32 */
# define MPSC_API
# endif
would any one can tell me why this coding will be the problem for my
program?
It might help if you told us exactly what the errors are, and why you
think those definitions are responsible for it.

Dave
Jul 20 '06 #2
thanks for the reply. after compliation(VS2005), the program can run
but when i click on certain button which will call the function from
the dll files , the program terminate immediately. So, i'm thinking
there is a problem in the code which use to load the dll files. But
when i run tha same program(complile from VS2003), it was no error.

there is a error message, state "debug assertion failed" which come
from commit.c.
_VALIDATE_RETURN((filedes >= 0 && (unsigned)filedes <
(unsigned)_nhandle), EBADF, -1);

would there is the possibility the problem is come from the dll files?

thanks

David Lowndes wrote:
hi, i have 1 MFC project which is written using VC++2003 but i need to
migrate to VC++2005. The program (VC++2003) is working fine. but there
is erros occur when running in VC++2005, and i just able to figure out
that the problem was come from the following code.
# ifdef WIN32
# if defined(MPSC_EXPORT)
# define MPSC_API __declspec( dllexport )
# elif defined(MPSC_IMPORT)
# define MPSC_API __declspec( dllimport )
# else /* for static libraries */
# define MPSC_API
# endif
# else /* !MD_WIN32 */
# define MPSC_API
# endif
would any one can tell me why this coding will be the problem for my
program?

It might help if you told us exactly what the errors are, and why you
think those definitions are responsible for it.

Dave
Jul 21 '06 #3
>thanks for the reply. after compliation(VS2005), the program can run
>but when i click on certain button which will call the function from
the dll files , the program terminate immediately.
OK, so debug your program and find exactly where it crashes.
>So, i'm thinking
there is a problem in the code which use to load the dll files.
You're guessing - don't! Debug it and find out exactly where it
crashes.
>would there is the possibility the problem is come from the dll files?
It's possible that you also need to rebuild the DLL with VS2005, but
you've not given us any information to know whether that might be the
case or not.

Dave
Jul 21 '06 #4

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

Similar topics

2
by: Peter Krikelis | last post by:
Hi, I have a C++ code. I tried to open and run in in VC++.Net and it gave me an error: fatal error C1083: Cannot open include file: 'getopt.h': No such file or directory Somehow it did not...
29
by: Stefan Slapeta | last post by:
There have been many announciations that VC 8.0 will finally support two phase template lookup; now, after I installing VC 2005 Express I had to realize that it still doesn't! What has happend...
5
by: AliR | last post by:
Hi Everyone, I have a Visual C++ MFC program, and I am trying to use a webservice written in C#. When I add the webservice to my project using Add Web Reference the sproxy compiler complains...
8
by: Edward Diener | last post by:
By reuse, I mean a function in an assembly which is called in another assembly. By a mixed-mode function I mean a function whose signature has one or more CLR types and one or more non-CLR...
1
by: Bonggoy Cruz | last post by:
We have a fairly big size ASP.NET web application that was written VB.NET. We are in the process converting the web project. We used the migration wizard included in VS 2005. I followed step by...
5
by: techie | last post by:
Hi, I'm a VC++ programmer with around 5 years of experience using VC++6. My company have plans to migrate to VS 2005 in the future. I know C++/CLI is pretty new and there aren't too many books...
14
by: John | last post by:
My friend told me that his company will migrate the VC++ win32 applications to C++ .NET windows applications. I don't understand why since currently Microsoft only supports .NET on windows...
4
by: jmnaste | last post by:
Hi, I tried to migrate data of an Access 2003 application (.mdb) to SQL Server 2005 Express. Using the Wizard and choosing 'create a new database', I receive (a French message saying roughly)...
7
by: Norman Diamond | last post by:
A project depends on VC runtime from Visual Studio 2005 SP1, and DotNet Framework 2. Options are set in the setup project properties, so if these two dependencies are not already installed then...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.