Home

A File-Based Application

 

Introduction to Databases

A database is a list of values that are organized to make the values easy to retrieve and optionally manipulate. A computer database is a list of values that are stored in the computer, usually as one or more files. The values can then be accessed when needed.

A computer database can be created using almost any application that can be used to store text. Because databases have become a valuable means of holding company information, specialized software products have been developed to make it possible to store large and complex pieces of information.

A file-based database (some people call a flat file database) is an application that stores one or various lists of information in regular, traditional text-based files.

Creating a File-Based Application

To create a file-based application, you can use a simple or complex text editor such as Notepad. The main action from you is to create the list(s) and save it(them) as text files using either the txt or any extension of you choice. After creating a list, when necessary, you can open it to access and optionally change the values. After making the changes, you can save the file. In the same way, you can print the values and do any type of file-related operation that you judge necessary.

One of the disadvantages of using a text editor to create a database is that, if you decide to distribute it, either your users should know as much as necessary about the file (it location and its content, just to name a few) you must provide a mechanical means of accessing the file(s). To make your product more professional and user friendly, you can create a graphical application that the user would use to access the values in the database. With this approach, you can create an attractive graphical user interface (GUI) object that display a functionality the user is familiar with. Using such an aesthetic interface, you can provide the means of adding, editing, deleting, or changing the values of the database.

To create a file-based application, you can use the C# language or the Microsoft Visual C# programming environment that, in combination with the .NET Framework, provides all the tools you would need.

Using Windows Controls and Accessories

To create an aesthetically user-friendly application, you can use the various Windows controls that are implemented in the .NET Framework. The controls are varied and are meant to accomplish different roles:

  • The form is the most fundamental control. As a container, in fact the main container, it is the primary object that holds the other controls of an application
  • Based on its fundamental role in an application, a form can be equipped with functional accessories placed on its frame and intended to assist with file or print operations. These accessories are the menu(s), the toolbar(s), and the status bar
  • A dialog box is a special type of form you create to perform the same actions as a form but it does not use the accessories and it may show a different type of border
  • On top of the form or the dialog box, there are controls, referred to as containers, that can be used to carry or hold other controls. These are the property sheet, the group box, or the panel
  • Text-based controls are used to receive or display text. These are the label, the text box, the masked edit box, and the link label
  • Some text-based controls can display enhanced or formatted text beyond the functionality of the traditional text box. Besides the formatting and the characteristics of their paragraph, they may also display pictures. These controls are the rich text box and the web browser
  • Button-based controls allow the user to perform an action when clicked. These controls are the command button, the radio button, and the check box
  • List-based controls display a list of items to the user. This type includes the list box, the combo box, the tree view, the list view, and the domain up/down
  • Date and time-based control are specialized to handle date and time values. The controls in this category are the calendar and the date/time picker
  • There are other controls used to show a value (the numeric up-down control) or a progress (the progress bar), etc
 

Home Copyright © 2007 FunctionX, Inc. Next