User Profile

Collapse

Profile Sidebar

Collapse
tracethepath
tracethepath
Last Activity: Oct 29 '07, 03:55 AM
Joined: Jun 29 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • tracethepath
    replied to infix to postfix notation
    in C
    Code:
     
    for(i = 0; i != '\n'; i++)
    basic problem i think is i cant be compared to a character type...
    i is an integer
    what you should do is

    Code:
    for(int i=0; exp[i]!='\0'; i++)
    See more | Go to post

    Leave a comment:


  • tracethepath
    replied to problem in modifying data in a binary file
    in C
    what is this " Serialise()"??
    i have not read this yet...
    can you explain a bit further?
    how to call it n do read and write operations using it?

    and all my class members are of char type...
    by the way my problem is solved now...i made a tempory file and went on writing the data until the data to be modified occured modified it and copied rest of the data to the temp file...and then removed original...
    See more | Go to post

    Leave a comment:


  • tracethepath
    replied to Problem with file handling in c++
    in C
    i can help u with your problem that the last record repeats twice.

    Your loop says:

    Code:
      while there is no file failure (eof):
        abc <-- read next record
        display abc
    What happens is this:
    Read record one (no file read failure), display record one.
    Read record two (no file read failure), display record two.
    ...
    Read record N (no file read failure),...
    See more | Go to post

    Leave a comment:


  • tracethepath
    started a topic problem in modifying data in a binary file
    in C

    problem in modifying data in a binary file

    hello everybody...
    i am trying to make a project on binary files and that needs a function to modify data in a binary file. I have made the following class.

    Code:
    class example
    {
       public:   
    
       char name[10], number[5];
       void getdetails();
       void showdetails();
    
       example()
       {
          name[0]='\0', number[0]='\0';
       }
    ...
    See more | Go to post

  • tracethepath
    started a topic Error in displaying or adding to a binary file
    in C

    Error in displaying or adding to a binary file

    the last record is getting displayed twice.i hv rechecked everything and cudnt find the error. here is the add n display function.
    [code=cpp]

    void add()
    {
    example abc;
    int n;
    ofstream file1("EXAMPLE. dat", ios::binary|ios ::app);
    cout<<"Enter Number Of Records To Add ";
    cin>>n;
    cout<<endl;

    for ( int i...
    See more | Go to post

  • tracethepath
    started a topic RUNNING D PROGRAM...need help urgently...
    in C

    RUNNING D PROGRAM...need help urgently...

    hello everybody,
    I am a beginner in C++. I got a CD with a C++ how to program,fifth edition book by Deitel which has the source codes included in the books. The source code for ATM case study is in parts i.e. user defined header files r dere which includes class definition, and class member function definition (cpp files) r dere 4 d same header file. Also there is one main cpp file to run the program. Now if i run the program by opening it...
    See more | Go to post

  • tracethepath
    replied to Give Some Ideas
    in C
    Thanx again Jos 4 ur kind concern...
    Wat i exactly know is abt classes and objects, data file handling, structures, arrays, functions and all...I know nothing about graphics in C++...And my project is supposed to be including the use of classes and objects and data file handling...My teacher has given me some ideas abt making a project on databases such as on Library i.e. all the books record and issued books and all...or that of hotel management...
    See more | Go to post

    Leave a comment:


  • tracethepath
    replied to Give Some Ideas
    in C
    thanx jos
    but i need to mke a project using classes and opjects and data files....

    regards...
    See more | Go to post

    Leave a comment:


  • tracethepath
    replied to Give Some Ideas
    in C
    Hi,
    thanx 4 ur concern. But i am just an C++ beginner and hav learnt classes and objects and data file handling and dont know anything about graphics, I dont think i will be able to do wat u suggested. Can u suggest some simpler projects? Or else can u elaborate how to do wat u suggested for.

    Thanx.....
    See more | Go to post

    Leave a comment:


  • tracethepath
    replied to Give Some Ideas
    in C
    Hi,
    thanx 4 ur concern. But i am just an C++ beginner and hav learnt classes and objects and data file handling and dont know anything about graphics, I dont think i will be able to do wat u suggested. Can u suggest some simpler projects? Or else can u elaborate how to do wat u suggested for.

    Thanx.....
    See more | Go to post

    Leave a comment:


  • tracethepath
    started a topic Give Some Ideas
    in C

    Give Some Ideas

    Hello everybody...i have to make a project based on C++...Can anyone give me some ideas on which to make the project...
    See more | Go to post

  • tracethepath
    replied to Doing File operations
    in C
    the function void delete is not working properly...It deletes all the data...and the function add, it adds the last entry twice..thanx 4 ur concern......
    See more | Go to post

    Leave a comment:


  • tracethepath
    started a topic Having trouble with file io
    in C

    Having trouble with file io

    i hav written a program code for reading characters from a text file and convert upper case characters to lower case and vice-versa. Converted characters need to be saved in a new text file and this new text file shud be read and displayed on the monitor. wat i am doing is firstly i open two text files in the following manner:[code=cpp]
    ifstream file1;
    ofstream file2;
    file1.open("EXA MPLE.txt");
    file2.open("WRI TE.txt");...
    See more | Go to post
    Last edited by sicarie; Jun 29 '07, 06:01 PM. Reason: Please use [code=cpp] and [/code] tags around your code. Thanks!

  • tracethepath
    replied to Doing File operations
    in C
    i am new to this...
    i was making a menu driven program on file operations..
    to add, delete, modify, search and display a particular record and list al the records...
    i have not yet written function modify...
    but the rest of the program shuld work properly but its not...
    its not doing searching by name properly and that deleting records...
    heres d code:
    [CODE=cpp] class example
    {
    public:...
    See more | Go to post

    Leave a comment:


  • tracethepath
    started a topic Doing File operations
    in C

    Doing File operations

    i am new to this...
    i was making a menu driven program on file operations..
    to add, delete, modify, search and display a particular record and list al the records...
    i have not yet written function modify...
    but the rest of the program shuld work properly but its not...
    its not doing searching by name properly and that deleting records...
    heres d code:
    [CODE=cpp] class example
    {
    public:
    ...
    See more | Go to post
    Last edited by r035198x; Jun 29 '07, 08:48 AM. Reason: added the missing code tags
No activity results to display
Show More
Working...