You should place a breakpoint in your code then step through it one step at a time and see which variables get which value on the bottom, or at least Visual Studio does it.
Type: Posts; User: Starr
You should place a breakpoint in your code then step through it one step at a time and see which variables get which value on the bottom, or at least Visual Studio does it.
Ok, here is the error: "warning C4700: uninitialized local variable 'stude' used"
And here is the code (You guys are so great! :))
#include <iostream>
#include <cmath>
#include <fstream>
Well, if it helps I don't take any class. I teach myself.
Now I am getting a wierd error when I try to run a program, I added a new function to obtain the averages of the grades entered. But I...
You said compile every few lines and not build. What is the difference because I build after each function or two I write, so what is the difference between building and compileing in VS C++ 2005?
I usually compile after I finish a function or two. If I am doing something simple I usually don't compile until the end of the program.
I use this line of code but when I go to the C:\ drive...
Thanks for the reply and everything works except that the file isn't created.
On a side note, how do you tell where you want to file to be placed?
Ok, I created a mess, and I am in 36 complier errors. Now, I fixed most of what I know how to fix but some of the errors I don't know how to fix and I am taking a different approach to this problem. ...
It is saying that you let the user enter two positive integers (1,2,3,4,....) and then compare the two and then show the user which one was larger and which one was smaller. This is simple.
We've all been there....
I am using XP Pro and thanks for the tutorials.
I threw it into Visual C++ and am getting a comple error that 'nocreate' is an undeclared identifier.
I am not sure if that will help you...
What I would try is using cin.get(); rather then...
Does anyone know of any good tutorials for GUI programming for C++? I am somewhat of a beginner/novice programmer. I know OOP and all the basics.
Don't you need to create an instance of the structure in main, or is that just classes?
instead of using std:: cout << "Hello";
simply add the line: using namespace std; after the included libraries, this way you won't have to add the std:: line.
I think what he is trying to say is why do they have ifstream and ofstream when we can use fstream.
My guess would be that if you have a program that does one or maybe the other it wouldn't be...
Wow, I can't believe I forgot about the "string" directory.
The code with the sting variable works now, thanks Daved and everyone else who had input.
That above was just an example here is the actual code I'm toying with:
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
1) Visual C++ 2005 Express Edition
2) The projects directory in C:\My Documents\Visual Studio 2005\Projects\Stuff\Stuff
3) The "test.txt" is in the same directy as the source which is ^^^^.
The...
Hello, I am somewhat new to C++ but one thing I can't seem to be able to figure out is how to have users inputed text into a text file using filestreams. I tried signing the users input to a string...