O'Reilly logo

Visual C#® 2012: How to Program, Fifth Edition by Harvey Deitel, Paul Deitel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

17.5. Creating a Sequential-Access Text File

C# imposes no structure on files. Thus, the concept of a “record” does not exist in C# files. This means that you must structure files to meet the requirements of your apps. The next few examples use text and special characters to organize our own concept of a “record.”

Class BankUIForm

The following examples demonstrate file processing in a bank-account maintenance app. These programs have similar user interfaces, so we created reusable class BankUIForm (Fig. 17.7) to encapsulate a base-class GUI (see the screen capture in Fig. 17.7). Class BankUIForm (part of the BankLibrary project with this chapter’s examples) contains four Labels and four TextBoxes. Methods ClearTextBoxes (lines 28–40), SetTextBoxValues ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required