Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. csv file problem

csv file problem

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestionannouncement
12 Posts 6 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M MsmVc

    what you want to do?if you have read data in buffer then must be contain data in buffer.I think some where in you code buffer have lost data.Please check it.

    U Offline
    U Offline
    User 589870
    wrote on last edited by
    #3

    when i run the application first time buffer contains correct data of file but when i close and run the application again and read file data in buffer then buffer contains empty?

    M L 2 Replies Last reply
    0
    • U User 589870

      when i run the application first time buffer contains correct data of file but when i close and run the application again and read file data in buffer then buffer contains empty?

      M Offline
      M Offline
      MsmVc
      wrote on last edited by
      #4

      First time your code work fine then you close exe and agaim run then show blank.Am i right?Please show code here?

      1 Reply Last reply
      0
      • U User 589870

        i read the data of a csv file in a buffer and then update the csv file.when i run the application and try to read the data again in buffer it shows empty even when file contains data.wat the problem may be?

        E Offline
        E Offline
        Eugen Podsypalnikov
        wrote on last edited by
        #5

        Member 590310 wrote:

        and then update the csv file

        What will be done here ? :)

        virtual void BeHappy() = 0;

        U 1 Reply Last reply
        0
        • E Eugen Podsypalnikov

          Member 590310 wrote:

          and then update the csv file

          What will be done here ? :)

          virtual void BeHappy() = 0;

          U Offline
          U Offline
          User 589870
          wrote on last edited by
          #6

          actually i detected the problem first time it copies all the data of file in buffer but in next executions it reads data from file only one character at a time.i dnt knw wat is the reason?

          E L 2 Replies Last reply
          0
          • U User 589870

            when i run the application first time buffer contains correct data of file but when i close and run the application again and read file data in buffer then buffer contains empty?

            L Offline
            L Offline
            LittleYellowBird
            wrote on last edited by
            #7

            Are you releasing the file properly when your application closes? :)

            Ali

            1 Reply Last reply
            0
            • U User 589870

              actually i detected the problem first time it copies all the data of file in buffer but in next executions it reads data from file only one character at a time.i dnt knw wat is the reason?

              E Offline
              E Offline
              Eugen Podsypalnikov
              wrote on last edited by
              #8

              Can you open your file by Notepad.exe before and after the first running ? :)

              virtual void BeHappy() = 0;

              U 1 Reply Last reply
              0
              • E Eugen Podsypalnikov

                Can you open your file by Notepad.exe before and after the first running ? :)

                virtual void BeHappy() = 0;

                U Offline
                U Offline
                User 589870
                wrote on last edited by
                #9

                yes i do there are no changes in file before and after running..

                E 1 Reply Last reply
                0
                • U User 589870

                  i read the data of a csv file in a buffer and then update the csv file.when i run the application and try to read the data again in buffer it shows empty even when file contains data.wat the problem may be?

                  D Offline
                  D Offline
                  David Crow
                  wrote on last edited by
                  #10

                  Member 590310 wrote:

                  wat the problem may be?

                  The problem may be that you've briefly described the issue, yet have shown no code to go along with that. At this point, it could be anything. Be specific!

                  "One man's wage rise is another man's price increase." - Harold Wilson

                  "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

                  "Man who follows car will be exhausted." - Confucius

                  1 Reply Last reply
                  0
                  • U User 589870

                    yes i do there are no changes in file before and after running..

                    E Offline
                    E Offline
                    Eugen Podsypalnikov
                    wrote on last edited by
                    #11

                    :confused: :-D :thumbsup: Do you read by the same function in the both cases ? :)

                    virtual void BeHappy() = 0;

                    1 Reply Last reply
                    0
                    • U User 589870

                      actually i detected the problem first time it copies all the data of file in buffer but in next executions it reads data from file only one character at a time.i dnt knw wat is the reason?

                      L Offline
                      L Offline
                      Lost User
                      wrote on last edited by
                      #12

                      Member 590310 wrote:

                      i dnt knw wat is the reason?

                      Probably there is a bug in your program! Try posting the relevant code so we can at least see what your program is trying to do.

                      It's time for a new signature.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups