ok I got a new problem after the Dbl Link list was solve.
The moving from one node to another and back works perfectly.
now the problem is the information retrieve from the file.
for example, ...
Type: Posts; User: hoangvo
ok I got a new problem after the Dbl Link list was solve.
The moving from one node to another and back works perfectly.
now the problem is the information retrieve from the file.
for example, ...
cout << "Please give the Day of the month" << endl;
cin.get();
cin >> Day_X;
change it around
cout << "Please give the Day of the month" << endl;
cin >> Day_X;
cin.get();
i did a few test and figure it out:
here is the new test loadFile():
void loadFile()
{
fstream ofile("Account.txt",ios::binary|ios::in);
if(!ofile.is_open()) return ; //1=no file exist
rootP is a pointer to an Account object but was instantiate at:
rootP=new Account
its in the loadFile() function
I have no problem moving the current Pointer (currP) starting from root to the...
I just found out my current point is not moving back at all.
any reasons or help?
Hi all,
I am having a problem with a double link list.
The list is loaded from a file, I got the list to move forward but cant seem to move backward.
Account.h:
#include <iostream>...
when declaring:
Account nAcnt1;
and
Account *nAcnt2;
I use do-while for my menu choice cause it makes sense to me.
int c;
do
{
system("cls");
cout<<"1- menu1\n";
cout<<"2- menu2\n";
cout<<"3- menu3\n";
Thank you,
I got it to work via binary method.
its a bit to remember but as i constantly type it i will eventually remember.
its abit confusing as well cause of...
opening a file in append mode so I can write info into it, only reason i m asking is because ios:app is hard to remember sometimes.
just other choices for opening a file that might be easier to...
is there any other way to open a file for append output other than:
ofstream afile("filename",ios::app);
??
thank you,
this is what i was missing as well.
the error was telling me that string is undeclare.
but after i included
using namespace std;
Yes I am trying to return the whole array. At first when I had teh code above complie and run it return me an address (229...). I save close poject and reopen it and recompile and run and it return...
ok now this is wierd.
I m using Dev C++
and now the function retFN() works and return teh value instead of the address ..
anyone help with how that happens?
Hi all, I am wondering if anyone can help me as I havent been programming in c++ for a long time and just went back. I did some basic c++ before but kind of lost the touch.
The problem I am trying...
can you post your new codes on and the new build?
else {
cout>>"Get out of my numbers.\n";
}
cout<<"Get out of my numbers.\n";
cin>>variabe (accept input to variable)
cout<<variable (display on screen)