Visual C++ Build without using .NET

Soldato
Joined
2 May 2004
Posts
19,950
you can write unmanaged C++ as a native windows application using the win32 libraries, or you can write a portable ANSI standard application using a set of standard C++ libraries. The former comes with Visual C++ (or it comes with my enterprise edition version ;) ) For the latter you can still use visual studio but you'll need to find a decent compiler (google for gcc). You can plug a 3rd party compiler / linker into visual studio quite easily if you like that enviroment.

To be honest I'm not totally sure what you'd want a Windows 2003 server SDK for over and above the .net SDk or the standard windows libraries?

HT
 
VC++ Express can compile native code, you just have to choose the right project type.

The Platform SDK is help files and samples for programming with the Win32 API. You don't "need" it although it's the best resource if you are planning to work with that API.
 
NathanE said:
VC++ Express can compile native code, you just have to choose the right project type.

The Platform SDK is help files and samples for programming with the Win32 API. You don't "need" it although it's the best resource if you are planning to work with that API.


Hmm, which project type would I choose?
When I chose Windows form I compiled it and then put it on my other PC which doesn't have .NET frame and it said the program configuration was incorrect.
happytechie said:
you can write unmanaged C++ as a native windows application using the win32 libraries, or you can write a portable ANSI standard application using a set of standard C++ libraries. The former comes with Visual C++ (or it comes with my enterprise edition version ;) ) For the latter you can still use visual studio but you'll need to find a decent compiler (google for gcc). You can plug a 3rd party compiler / linker into visual studio quite easily if you like that enviroment.

To be honest I'm not totally sure what you'd want a Windows 2003 server SDK for over and above the .net SDk or the standard windows libraries?

HT

Hmm, I was told that I would need the SDK to compile programs without using .NET in VC++ or is there just something special I need to do for it not to use .NET?

Craig.
 
Last edited:
Yeah, a console application will run without .NET, but I just do my console applications with Dev-C++.

I'm wanting to make an application (I've been told it's possible) using Visual C++ (so the ability to drag the buttons etc. in) and then compile it so it doesn't require .NET framework.

Thanks
Craig.
 
VC++ doesn't have the same excellent drag'n'drop IDE facilities as .NET.

You have to make your dialogs and such in the Resources file (by dragging the components where you want) then you can implement their functionality in your code.

I believe MFC takes some of the load off in terms of wiring up control events.

Not for the faint of heart.
 
You have to make your dialogs and such in the Resources file (by dragging the components where you want) then you can implement their functionality in your code.

Hmm, I'm really not sure where you mean. I made a new Win32 application and now down the left I have header files, resource files, source files and under the top two have 3 items and in the bottom one have 2 items. I have checked everywhere but van't find anywhere that will allow me to drag in the components I want :(

Thanks
Craig.
 
Craig321 said:
Hmm, I'm really not sure where you mean. I made a new Win32 application and now down the left I have header files, resource files, source files and under the top two have 3 items and in the bottom one have 2 items. I have checked everywhere but van't find anywhere that will allow me to drag in the components I want :(

Thanks
Craig.

it sounds to me like you want to get hold of an older version of visual studio.. VC++ 6 is the one you are after. This will give you the visual drag and drop of compobnents onto your windows forms. Of course any apps you produce will be windows only so you may as well use .net :D

HT
 
I don't think so, you can still write MFC in .net but it's unmanaged code wtf that means. In real world terms all that you've lost is the window building via drag and drop but the MFC code produced by dragging and dropping components was so hideous that I think everyone used to code them form scratch.

Visual Studio 2005 tries to make you do everything GUI through .net.

I can't think of ANY good resons to write a windows GUI in anything other than .net today. Of course portability / legacy OS support would be nice but I think MS consider anything other than vista to be legacy now.

HT
 
happytechie said:
I don't think so, you can still write MFC in .net but it's unmanaged code wtf that means. In real world terms all that you've lost is the window building via drag and drop but the MFC code produced by dragging and dropping components was so hideous that I think everyone used to code them form scratch.

Visual Studio 2005 tries to make you do everything GUI through .net.

I can't think of ANY good resons to write a windows GUI in anything other than .net today. Of course portability / legacy OS support would be nice but I think MS consider anything other than vista to be legacy now.

HT

So, to all intents and purposes, its RIP MFC? Hoorah!

May you take your DWORDS and your relentless (void*) casts with you....
 
I have visual studio 2005, and i was wondering if there was a way to make it use the .net1.1 runtimes instead of the 2.0 ones?

My project doesn't have any .net2.0 specific code in it, and dropping to 1.1 will mean it'll run on more systems.

(I don't know why microsoft doesn't make .net2.0 a mandatory update, as they are trying to promote it so hard.)

Any ideas?
 
DWORDs and all that are still there. They are part of the Win32 API. I don't know why people always get so uptight about them. They're just macro's...

MFC is just a bunch of classes to simplify everyday Win32 API tasks.

Really unmanaged C++ as a whole has been deprecated in the Microsoft development world. .NET has superceded it in every area. It is now also possible to write Managed C++ code... a.k.a. C++/CLI.
 
Last edited:
happytechie said:
I can't think of ANY good resons to write a windows GUI in anything other than .net today. Of course portability / legacy OS support would be nice but I think MS consider anything other than vista to be legacy now.

HT

Only reason why I want to write C++ w/o .NET is so it works on any Windows PC. a lot of people won't install .NET just to look at an application.

Was looking at VS 2003 earlier and it's pretty easy to make a C++ application in there w/o using .NET although for some strange reason you can't edit the main part of the main form!! :(

happytechie said:
it sounds to me like you want to get hold of an older version of visual studio.. VC++ 6 is the one you are after. This will give you the visual drag and drop of compobnents onto your windows forms. Of course any apps you produce will be windows only so you may as well use .net :D

HT

The one I was trying to do it with was Visual C++ Express 2005 which didn't want to let me make an application without using .NET. VS 2003 is letting me make an application without using .NET, but some parts are still quite complicated.. like the fact that it's not letting me edit the main part of the main form :eek:

Isn't VC++ 6 really old?

Craig.
 
Last edited:
yes VC++ 6 is ancient.

the reason that VS 2005 and 2003 make you build windows forms in .net is because that's the technology that MS are pushing at the moment. If people want to use your application they'll install .net. Include the runtime with the installer for your product and make them deal with it tbh. You can still write MFC and win32 apps in VS 2005.

file -> new project -> other languages -> Visual C++ -> MFC -> MFC application

or

file -> new project -> other languages -> Visual C++ -> win32 -> win32 Project

those are the pathe in VS2005 enterprise edition so the express versions might be a tad different, I suspect the same but without the other languages bit.

assuming that you'll be using MFC rather than plain ole win32 libraries you need to build the UI for your app using resource files. you really can I've just built one ;) you get a main form, multiple document support, open and close buttons etc for free

have fun.

HT
 
Back
Top Bottom