Search:

Type: Posts; User: cmasri

Search: Search took 0.00 seconds.

  1. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    where is the faq?

    where is the faq?
  2. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    void ListFileHDD(ifstream& fin) { char...

    void ListFileHDD(ifstream& fin)
    {
    char line[500];


    while (!fin.eof())
    {
    fin.getline(line,'\n');
    }
    cout<<line;
  3. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    ms visual studio.net 2003

    ms visual studio.net 2003
  4. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    yes it compiles....

    yes it compiles....
  5. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    I already did, i'm still stuck void...

    I already did, i'm still stuck


    void ListFileHDD(ifstream& fin)
    {
    string line;
    while( getline(fin, line) )
    {
    cout<<line<<endl;
    }
  6. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    getting error C3861: 'getline': identifier not...

    getting error C3861: 'getline': identifier not found, even with argument-dependent lookup
  7. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    it did not compile... error C2039: 'getline' :...

    it did not compile...

    error C2039: 'getline' : is not a member of
    error C3861: 'getline': identifier not found, even with argument-dependent lookup
    error C2679: binary '<<' : no operator found...
  8. Thread: file I/O

    by cmasri
    Replies
    17
    Views
    4,055

    file I/O

    void ListFileHDD(ifstream& fin)
    {
    string line;
    while (!fin.eof())
    {
    getline(fin,line);
    }
    cout<<line;
    }
  9. Replies
    2
    Views
    1,203

    trouble outputing string object to screen.

    void ListFileMem(StudentRecord** Records, int numRecords){
    cout<<"LIST RECORDS FROM MEMORY";
    string fullname, firstname, lastname;
    if (numRecords>0)
    {
    for (int k=0; k<numRecords;k++)
    {...
  10. Replies
    9
    Views
    1,407

    void ListFileMem(StudentRecord** Records, int...

    void ListFileMem(StudentRecord** Records, int numRecords){
    cout<<"LIST RECORDS FROM MEMORY";
    string fullname, firstname, lastname,space(" ");
    if (numRecords>0)
    {
    for (int k=0;...
  11. Replies
    9
    Views
    1,407

    thank you that works. another question....

    thank you that works.
    another question....
  12. Replies
    9
    Views
    1,407

    the loop that you are referring to is copying old...

    the loop that you are referring to is copying old data from a temporary array.

    made improvements according to your suggestion, is that better?

    StudentRecord**Temp; /*Declare array of pointers...
  13. Replies
    9
    Views
    1,407

    the value of num records is 0 when that line...

    the value of num records is 0 when that line executes.
  14. Replies
    9
    Views
    1,407

    it is an assignment requirement to do it this...

    it is an assignment requirement to do it this way. It's the prof's specification. What would it look like in vectors anyway?
  15. Replies
    9
    Views
    1,407

    Are there any memory leaks here??

    bool AddRecord(StudentRecord**& Records, int& numRecords){
    /*Please tell me if I have memory leaks.*/
    /*
    struct StudentRecord
    {
    char* firstName; // student key
    char* lastName; //...
  16. I don't understand this code. It is an assignment...

    I don't understand this code. It is an assignment requirement to program it with array of pointers to struct. see http://ca.geocities.com/[email protected] assignment0 for your reference.
  17. Thank you it works!!

    Thank you it works!!
  18. Help with dynamically allocated array of pointer to a structure.

    bool AddRecord(StudentRecord**& Records, int& numRecords){
    struct StudentRecord
    {
    char* firstName; // student key
    char* lastName; // student name
    int id; //student id
    float mark; //...
Results 1 to 18 of 18