Archived

This topic is now archived and is closed to further replies.

EbonySeraph

Using Visual C++ help...

Recommended Posts

I am making programs with Direct X with VC++ and everytime I make a new Win32 project that is an "empy application" I get nothing. Meaning I get blank workspace with no where to add source code. If I add a class then it allows me to add scoure code, but it puts it in a header file. And my whole program seems to just be a class(with the WinMain function in it). If I create a simple Win32 Application I get two more files something like stdafx.h and stdafx.cpp. But even then, in order to edit source code I have to pull down the list of globals and double click on one of the functions or variables before I get anything in the main window that allows me to write code. How can I create a project with ONE source file, that is everything I need. And all headers or source code is written by me?(expect for the SDK files...) Or how maybe how would I be able to make an empty Win32 application and add source code WITHOUT adding a new class? That''s why I like Borland more...you have much more control. "Ogun''s Laughter Is No Joke!!!" - Ogun Kills On The Right, A Nigerian Poem.

Share this post


Link to post
Share on other sites
File...
New...
Create Workspace...

(Enter Name of workspace)
(Enter directory of workspace)

File...
New...
Create Project...
Win32 Application...

(Enter Name)
Empty Project...
Finish...
OK...

Double Click on project name.
Double Click on "Source Files"


File...
New...
Files...
C++ Source File....

(Enter Source File Name)

Start Coding....

You can also add files by Right Clicking on the "Source Files" folder and choosing "Add Files to folder." Type in the name of the cpp file..click yes, then find that file and double click on it. Answer yes and start coding.


Edited by - evaclear on June 25, 2001 10:56:08 AM

Share this post


Link to post
Share on other sites
Not sure how you can say you have more control in Borland with all those extensions they add by default which come standard on nobody elses computers and don''t tell you how to disable them.

First create your project (empty win32 application).

Now go to File->New and create a new C++ source file or C/C++ header file and put the name of the file you want to create in the box on the right.

Also if you have source files that you already created which you want to include in your project just go to Project->Add To Project->Files.

Now as for being able to edit source code when you create a new Simple Win32 Application.

In MSVC by default your little tree on the left hand side is set to ClassView. This means that it shows a list of all the classes that are created in your source files. At the bottom of this tree view there are some tabs including: ClassView, and File View. If you click on File View you will get some folders like Source Files, Header Files, Resource Files, etc... Open up Source Files and you should see a source file with the same name as the project you created. Double click on it and open up the source
Add your own source by File->New->C++ Source File.

Seeya
Krippy

Share this post


Link to post
Share on other sites