Page 292
The Button Palette check box places a default button palette at the bottom of the form. The palette contains buttons to navigate up or down, scroll up, scroll down, query a record, and save the changes.
The Scrollbar check box is used to place a scrollbar on the block. It's generally used when the block contains multiple records.
The Master/Detail tab is used to create master-detail blocks, which are two related blocks. It also creates some special triggers that coordinate the two blocks. This tab is discussed in Chapter 14, "Creating and Modifying Master-Detail Forms."
Everything is now filled in and you can create the block. Press the OK button.
The dialog box disappears and the Object Navigator contains some new objects. These objects consist of the block called "One" and the selected items from the Items tab.
Figure 12.32 shows the new objects in the Object Navigator.
FIG. 12.32
The Object Navigator
after the new block
"One" is created.
CAUTION |
Each of the four tab sheets on the New Block options dialog box has an OK button. Pressing this button causes the block to be created, even if you've never viewed some of the tab sheets. |
The next step is to name the file. Since this is a new file, it has a default name beginning with "module." You can change the name of the form in the Object Navigator.
Double-click the form name. This highlights the name. Press the Backspace key. This deletes the name. Now type in the new name.
Page 293
Figure 12.33 shows the Object Navigator after this sequence. You can use this procedure to update any object name.
FIG. 12.33
The Object Navigator
after the form name is
highlighted
and changed.
The last step is to save the file. You can do this by pressing the Save button on the tool palette or by selecting the file/save option on the menu bar.
TIP |
A number of techniques are useful and time saving when you create a form. You can use the names "one," "two," "three," "four," and "five" for your block names rather than the default names. |
Forms Designer is used to develop the form applications. When Forms is launched, the first screen is the Object Navigator, the main Forms Designer screen. It contains all the objects that can be changed, and offers an easy mechanism to reach all form, menu, and library objects.
Page 294
The Object Navigator has several parts. The top of the screen contains menu options, the left side of the screen contains a tool palette, the bottom of the screen displays messages, and the center of the screen displays the objects.
The objects are arranged in levels. The highest-level objects can be expanded to expose the child objects. The objects can also be collapsed to make the Object Navigator easier to read.
The File menu options offer a variety of options. There are options to open, save, close, and generate the files.
The Edit menu options allow you to cut, copy, paste, clear, and duplicate items.
The Tools menu options are used to display an item's property sheets, Layout Editor, Object Navigator, Menu Editor, PL/SQL Editor, and the Object Navigator. This menu is used to create new blocks and to call a special dialog box that creates select statements.
The Object Navigator menu has options to change the arrangement of the objects in the Object Navigator. It also has options to add and delete objects, as well as to expand and collapse them.
You can create a form by highlighting the forms object in the Object Navigator and clicking the Create icon. Then you add a block to the form. You do this by selecting the blocks object and pressing the Create icon.
A dialog box is displayed with a variety of settings that determine the type of form created. After you mark these settings, Designer creates the form. You can then save and run the form.
The next chapter covers the Layout Editor, a screen painter that is used to format a form. The chapter discusses the formatting options available, including arranging and coloring items, adding text, placing images, changing fonts, viewing options, and formatting the form created in this chapter.
Be sure to save the forms. You'll use them in the exercises for Chapter 13.