Jump to content
  • Advertisement
Sign in to follow this  
soconne

[.net] create C++ winforms project WITHOUT CLR

This topic is 4448 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

In Visual Studio 2003 if you create a WinForms project in C++, by default you get the regular C++ style syntax and none of the CLR stuff. But in Visual Studio 2005 the project automatically gets created with CLR and so pointers (*) turn into (^) and using statements get added. How can you create a C++ Winforms project in VS2005 without this happening? How can you create it without CLR and just plain C++?

Share this post


Link to post
Share on other sites
Advertisement
I don't think you got the regular C++ style syntax, you got the really dodgy 'managed bits tacked onto C++' syntax. With VS2005 they've dramatically *improved* the syntax (which is called C++/CLI). You simply cannot get WinForms without the CLR, since all of the WinForm classes themselves are managed code.

Share this post


Link to post
Share on other sites
But in VS2003 you can create a winforms C++ project without all the odd C++ syntax. And I can then load that project into 2005 and compile just fine. So there must be a way to create it in 2005.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Quote:
Original post by soconne
But in VS2003 you can create a winforms C++ project without all the odd C++ syntax. And I can then load that project into 2005 and compile just fine. So there must be a way to create it in 2005.


Compare the settings to see if there is a switch not set in VS 2005.

Share this post


Link to post
Share on other sites
Well that's the thing, when you create the project in VS2005 there is no switch. There are no settings, just the "ok" button.

Share this post


Link to post
Share on other sites
Quote:
Original post by BradSnobar
can you still create an mfc application?


Yes MFC is still supported in Visual Studio 2005.

Share this post


Link to post
Share on other sites
2003 had "Managed C++"
2005 has "C++/CLI"

two different languages, but NONE of those are ordinary c++. both are c++ in a managed world. 2003 just looks like ordinary c++, wich is quite dangerous. 2005 does add difference to make it obvious wich part of the code is managed, and wich isn't.

afaik 'Managed C++' got deprecated in 2005 => you can't normally create projects using it. but you can still compile the old code using it (against the .net 1.1 framework, that is, i guess). so better check the options in the project (not at creation time, but afterwards. rightclick the project in the projectbrowser, and choose settings)

Share this post


Link to post
Share on other sites
as long as you don't need winforms or anything else that IS .NET-based, you don't need the CLR, and can disable it in the options. and then you can continue coding as usual.

but if you want to use anything of .NET, you obviously have to .. use .NET. winforms are .NET, ergo there's no way around it. but you can use win32 if you want (but i won't suggest it to you ever...).

possibly you should just not be scared of .NET, it's a great tool for a lot of things.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!