Chapter 13: Saving and Retrieving Stuff in Files . . . . . . . . . . . . . . . . .175 Storing Stuff in Text Files ............................................................................175 Creating a new text file .....................................................................176 Putting stuff in a text file ..................................................................176 Adding new stuff to an existing text file .........................................177 Retrieving data from a text file ........................................................178 Storing Stuff in Random-Access Files .......................................................180 Creating a new random-access file ..................................................181 Saving data into a random-access file ............................................183 Retrieving data from a random-access file .....................................184
Saving and Retrieving Data in a Binary File .............................................186 Creating a new binary file .................................................................186 Saving stuff in a binary file ...............................................................187 Changing stuff in a binary file ..........................................................187 Retrieving stuff from a binary file ...................................................189
Chapter 14: Creating a User Interface . . . . . . . . . . . . . . . . . . . . . . . . . .191 Designing a Window ....................................................................................191 Creating a new window .....................................................................192 Defining the size and location of a window ...................................193 Adding color to a window ................................................................194 Putting Pull-Down Menus in a Window ....................................................195 Making Pop-Up Menus ................................................................................198 Putting Controls in a Window ....................................................................200 Creating a command button ............................................................200 Displaying text ...................................................................................203 Creating a check box .........................................................................204 Creating a radio button .....................................................................205 Creating text boxes ...........................................................................207 Creating list boxes .............................................................................209 Creating combo boxes ......................................................................211 Creating group boxes ........................................................................213
Chapter 15: Debugging Programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . .215 Anatomy of a Computer Bug ......................................................................215 Syntax Errors ...............................................................................................216 Run-Time Errors ..........................................................................................218 Fun with Logic Errors .................................................................................219 Stepping line by line ..........................................................................220 Tracing through your program ........................................................221
Part IV: Dealing with Data Structures ........................223
Chapter 16: Storing Stuff in Arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . .225 Making an Array ..........................................................................................226 Storing (and Retrieving) Data in an Array ...............................................228 Making a Multidimensional Array .............................................................230 Creating Dynamic Arrays ...........................................................................232
Untitled Part 1
Comenzar desde el principio
