
-----------------------------------
abrar1434
Wed Jun 08, 2011 11:25 am

Trouble setting up Visual Studio 2005
-----------------------------------
Currently, I am following a free online course provided by Stanford University titled Programming Abstractions (CS106B) in order to further my understanding of the field. The assignments in the class are all written in C++.  Completion of the course material requires that one uses solely Visual Studio 2005; this is due to the fact that the course uses special libraries in order to simplify the syntax of C++. I have managed to install Visual Studio 2005 Professional, as well as setup the required libraries. However, the compiler seems to not fully function. The handout explaining the usage of VS2005 is included here: http://see.stanford.edu/materials/icspacs106b/H05P-UsingVisualStudio.pdf


Sample Program
[code]
#include 
#include "genlib.h"

int main() {

	for (int i = 0; i < 5; i++) {
		cout ------ Rebuild All started: Project: Assignment Two, Configuration: Debug Win32 ------
1>Deleting intermediate and output files for project 'Assignment Two', configuration 'Debug|Win32'
1>Compiling...
1>mycode.cpp
1>Linking...
1>CS106CPPLib.lib(genlib.obj) : warning LNK4204: 'c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\vc80.pdb' is missing debugging information for referencing module; linking object as if no debug info
1>CS106CPPLib.lib(init.obj) : warning LNK4204: 'c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\vc80.pdb' is missing debugging information for referencing module; linking object as if no debug info
1>CS106CPPLib.lib(pcgraphics.obj) : warning LNK4204: 'c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\vc80.pdb' is missing debugging information for referencing module; linking object as if no debug info
1>CS106CPPLib.lib(strutils.obj) : warning LNK4204: 'c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\vc80.pdb' is missing debugging information for referencing module; linking object as if no debug info
1>Embedding manifest...
1>Build log was saved at "file://c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\BuildLog.htm"
1>Assignment Two - 0 error(s), 4 warning(s)
========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========
[/code]

I know it's a lot to ask in terms of aid for this situation, but it would be great if someone could help me out with this problem. I do hope I've included enough information.

-----------------------------------
Tony
Wed Jun 08, 2011 2:32 pm

RE:Trouble setting up Visual Studio 2005
-----------------------------------
The executable file is probably saved in

c:\Users\abrar\Desktop\Stanford\CS106B\Assignment Two\Assignment Two\Debug\

run it from your shell (command line/prompt) of choice.

-----------------------------------
abrar1434
Wed Jun 08, 2011 6:07 pm

RE:Trouble setting up Visual Studio 2005
-----------------------------------
Sorry I forgot to mention that I had tried that prior to my post. That still doesn't seem to work. 

Whenever the executable is run I get two messages saying "Can't find console window" and "CSLib environment cannot initialize properly. The program cannot run." 

If I take my code, and put it into an Empty Project instead of a  CS106B/X C++ Assignment Wizard and remove the line #include "genlib.h" everything seems to work fine. So I had assumed the issue would have something to do with the CS106 library.

Edit: The problem has been solved.
