Hi,

My friend have a problem with running c++. She's using windows vista home basic. She's able to install C++ and run it but when she tries to launch any program she wrote, it pops out saying that it has a compatibility issue with this version of windows. Any ideas about what's wrong with it or how to fix it? thanks.

I believe it's a known problem. I don't have a solution offhand but unless you are needing 6.0 for MFC or ATL work then you should probably grab the 2008 express edition (http://www.microsoft.com/express/Downloads/#2008-Visual-CPP) it does console programs, Win32, and Winforms via C++/CLI.

commented: Good advice. +26

I believe it's a known problem. I don't have a solution offhand but unless you are needing 6.0 for MFC or ATL work then you should probably grab the 2008 express edition (http://www.microsoft.com/express/Downloads/#2008-Visual-CPP) it does console programs, Win32, and Winforms via C++/CLI.

Would the syntax be different for the 6.0 version and the 2008 express edition version?

No. The 2008 compiler is more compliant with the C++ standard (see something like this for the few ways the 2008 compiler is not compliant-- they don't have a listing for 6.0 any longer) so it may pick up more corrections but it will make your code more compliant by extension.

thank you very much for your advice :)

You might have to make a few minor changes to your program, depending on how you coded it. For example

for(int i = 0; i < something; i++)
   cout << "Hello\n";
if( i > 10)
   // blabla

VC++ 6.0 will allow the above code but c++ standards and VC++ 2008 will not because of scoping rules for integers declared inside the for statement.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.