2 Replies - 525 Views - Last Post: 07 November 2009 - 06:26 PM Rate Topic: -----

#1 dominion_vortar  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 52
  • Joined: 07-November 09

Reading and Writing to a file

Post icon  Posted 07 November 2009 - 04:02 PM

Hi.

I'm creating a project where I need to store information in two files. As I understand, I can store information in a text file or a binary file?

1. Is this correct?
2. What are the advantages / disadvantages of each method?

Sorry, I'm a complete noob... :crazy:
Is This A Good Question/Topic? 0
  • +

Replies To: Reading and Writing to a file

#2 Sue816  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 92
  • Joined: 22-April 09

Re: Reading and Writing to a file

Posted 07 November 2009 - 04:15 PM

View Postdominion_vortar, on 7 Nov, 2009 - 03:02 PM, said:

Hi.

I'm creating a project where I need to store information in two files. As I understand, I can store information in a text file or a binary file?

1. Is this correct?
2. What are the advantages / disadvantages of each method?

Sorry, I'm a complete noob... :crazy:


Probably just do a text file, but a binary file containing only text will give you plain text. Otherwise, it will give you an encoded file. Just depends on what you want, but .txt is probably easist.
Was This Post Helpful? 0
  • +
  • -

#3 dzone41  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 46
  • View blog
  • Posts: 216
  • Joined: 21-August 09

Re: Reading and Writing to a file

Posted 07 November 2009 - 06:26 PM

Look into the StreamWriter / StreamReader classes, this is the easiest way to go.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1