C++ and Visual Studio .Net 2003

Started by
8 comments, last by MajesticKnight 20 years ago
Is there anyway to program normal C++ in Visual Studio .Net 2003? My compiler can''t seem to find and I really don''t want to do my programs managed style. Only reason I''m using .Net 2003 is because I can''t get Visual Studio 6 to install anymore, says something about a DCOM not being able to be registered for valec. Anyway, hopefully there is a way, i''ve searched msdn, found nothing, i''ve been using the internet for over 2 hours and have found nothing. fyi this is for a DLL file. "Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein ------------------------------ Dan Ronning Founder, Lead Programmer Majestic Knight Game Dev.
"Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein ------------------------------Dan RonningFounder, Lead ProgrammerMajestic Knight Game Dev.
Advertisement
Yes. Just start a normal non-managed Windows Application. Select Win32 Project from the new project dialog and click the nice DLL radio button in the screen after that.
Ya I did that, but when I go to compile it comes up with a fatal error saying iostream.h doesn''t exsist.

"Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein
------------------------------
Dan Ronning
Founder, Lead Programmer
Majestic Knight Game Dev.
"Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein ------------------------------Dan RonningFounder, Lead ProgrammerMajestic Knight Game Dev.
iostream.h is pre-standard. It really doesn''t exist in standard C++. You need to switch to the <iostream> header for your code.
If you use <iostream> instead of <iostream.h> remember that all the C++ standard libary stuff is in the std namespace, so instead of cout you have std::cout etc. If you're feeling lazy you can just put using namespace std; at the top of your file.

[edited by - Monder on April 14, 2004 4:20:00 PM]
lol but I like being lazy. I prefer *.h then just no *.h don''t like using name spaces much. either lol. But anyway, I don''t know why it doesn''t allow it in the visual studio .net 2003, justs not right.

"Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein
------------------------------
Dan Ronning
Founder, Lead Programmer
Majestic Knight Game Dev.
"Computers are incredibly fast, accurate and stupid. Human beings are incredibly slow, inaccurate and brilliant. Together they are powerful beyond imagination." - Albert Einstein ------------------------------Dan RonningFounder, Lead ProgrammerMajestic Knight Game Dev.
Yes, it is right. <iostream.h> is not part of the C++ language, so the compiler is shipped without it; this does not strike me as odd or wrong. See the C++ FAQ Lite for a few more details.
quote:Original post by MajesticKnight
lol but I like being lazy. I prefer *.h then just no *.h don''t like using name spaces much. either lol. But anyway, I don''t know why it doesn''t allow it in the visual studio .net 2003, justs not right.
Ha. You are quite the opposite of me, I don''t like the ".h"
quote:Original post by MajesticKnight
lol but I like being lazy. I prefer *.h then just no *.h don''t like using name spaces much. either lol.

It''s not optional. It''s <iostream> or nothing.

--
AnkhSVN - A Visual Studio .NET Addin for the Subversion version control system.
[Project site] [Blog] [RSS] [Browse the source] [IRC channel]
--AnkhSVN - A Visual Studio .NET Addin for the Subversion version control system.[Project site] [IRC channel] [Blog]
Indeed... we should be thanking MS for finally sticking to the standard instead of letting us hold on to deprecated syntax.

This topic is closed to new replies.

Advertisement