Thread: searching for a specific item in a C++ file

  1. #1
    Registered User
    Join Date
    May 2002
    Posts
    7

    searching for a specific item in a C++ file

    hey,

    i have a written a C++ class to a file. i can print the entire contents of the file eg.

    ID NAME ADDRESS AMOUNT
    100 John China 100.00
    200 Tom Iran 500.00
    300 Ann Japan 600.00


    my problem is, i can only print all the info from the file at once i cant print the information specific to id #200 ...Tom.

    Could i get some help please ?

    thanks
    Stan

  2. #2
    Registered User
    Join Date
    May 2002
    Posts
    317
    Check out this thread, it should give you what you need:

    http://www.cprogramming.com/cboard/s...threadid=19055

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Formatting a text file...
    By dagorsul in forum C Programming
    Replies: 12
    Last Post: 05-02-2008, 03:53 AM
  2. Need Help Fixing My C Program. Deals with File I/O
    By Matus in forum C Programming
    Replies: 7
    Last Post: 04-29-2008, 07:51 PM
  3. Inventory records
    By jsbeckton in forum C Programming
    Replies: 23
    Last Post: 06-28-2007, 04:14 AM
  4. Post...
    By maxorator in forum C++ Programming
    Replies: 12
    Last Post: 10-11-2005, 08:39 AM
  5. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 09:54 AM