Chapter Contents |
Previous |
Next |
SAS/FSP Software Procedures Guide |
Select option 2 from the FSEDIT Menu window to create a customized display for your application. Customization is a three-step process:
Step 1: Modifying the Display |
The first window that opens when you select option 2 from the FSEDIT Menu window is the FSEDIT Modify window. In this window you design a customized display for your application. Variable fields can be labeled more descriptively, rearranged, and even deleted. You can add comments to help users enter data in the proper format.
The FSEDIT Modify window initially contains the display format for the FSEDIT window (either the default format if a new SCREEN entry is being created, or the previous customized format if an existing SCREEN entry is used.) During this first step, the entire contents of the FSEDIT Modify window are unprotected, so you can type over any area in the display, including the variable names. You can move, delete, or insert any lines in the display. You can move variable fields and add any special comments or instructions that would make entering data easier.
If the modified display format that you create has more lines than the number of rows in the FSEDIT window, a multiscreen application is created. Users must scroll to view the fields and text that do not fit in the first screen. Option 5 in the FSEDIT Menu window enables you to specify the initial height of the FSEDIT window.
Creating Fields |
There are three important requirements for variable fields in a customized display:
__* - __* - ____
Note: The restriction of using an underscore as the
field pad character is applicable only when you are identifying fields to
the FSEDIT procedure. This rule does not affect the final appearance of the
display. If you want to use a pad character other than the default underscore
to mark the location of a variable field, use option 4 from the FSEDIT Menu
window to change the PAD attribute for the field.
The default width of each variable field depends on how the variable is stored in the data set and on whether the variable has an associated output format:(footnote 1)
Variable Type | Default Width | |
---|---|---|
character | the larger of | |
the width of the variable in the data set | ||
the width of the variable's format or informat (whichever is longer), if one has been assigned. | ||
numeric | either | |
the width of the variable's format or informat (whichever is longer), if one has been assigned | ||
the default width of 12 (because BEST12. is the default numeric format). |
You can modify the default field widths when you create a customized display. For example, many numeric fields do not require the full default width of 12 positions. However, you should ensure that the width of the field is appropriate for the width of the corresponding variable. Otherwise, users of your application may be unable to enter the full range of valid variable values in the fields.
Creating Special Fields |
In addition to variable fields, you can create two different types of special fields:
Repeated fields are useful in multiscreen applications when you want certain fields to appear on more than one screen.
These special fields are defined in the same manner as variable fields, with a series of underscores that are preceded and followed either by a blank or by the edge of the window.
FSEDIT Modify Window Commands |
When designing a display in the FSEDIT Modify window, you can use all of the SAS/AF global commands and all of the SAS text editor commands.
Note: Because the
Modify window uses the SAS text editor, you
can use the editor's spell checking feature. To check the spelling of the
descriptive text in the window, use the SPELL ALL command.
Specifying Color and Highlighting |
If your terminal or workstation supports color and highlighting, you can change the attributes of the text in your customized display. When your application is used, the color information is ignored if the user's device does not support color. If you have used a color that is not available on the user's device, the procedure substitutes the available color that most closely matches the specified color.
Use the global COLOR TEXT command to change the color and highlighting attributes of the text you enter. For example, the following command changes all of the text you type after the command is issued to high-intensity blue:
color text blue hOnce you enter a COLOR TEXT command, the specified attributes are used until you change them with another COLOR command. Refer to the description of the COLOR command in the online Help for base SAS software for additional details.
Note: Some terminals or workstations provide special keys that
control text color and highlighting. If your device has such keys, you can
use them to set color and highlighting attributes as you enter the text.
Exiting the FSEDIT Modify Window |
Issue the END command to close the FSEDIT Modify window. Before the window is closed, the FSEDIT procedure displays the following question:
Did you create any computational or repeated fields (Y or N) ? _
Your response determines whether you go directly to the field identification step or enter the field definition step first.
If you have added any special (computed or repeated) fields, type a Y
in the space provided. You then enter
the field definition
step (step 2), where you can define the fields you have added. Otherwise,
type an N
in the space provided. The procedure
then takes you directly to the field identification step (step 3).
Step 2: Defining Fields |
When you indicate in the FSEDIT Modify window that you have created special fields, the FSEDIT Names window is opened when the FSEDIT Modify window is closed. In the FSEDIT Names window you define the characteristics of special fields. The FSEDIT Names Window shows the initial FSEDIT Names window display.
All of the entries in the FSEDIT Names window are initially blank. Special fields that are added during customization are unknown to the FSEDIT procedure until they are defined in the FSEDIT Names window. Special fields are used to hold repeated values or computed values from the program. Do not confuse defining special fields with adding variables to an existing SAS data set.
Defining Special Fields |
The rules for defining special fields are similar to the rules for defining SAS variables when you create a new data set:
N for numeric fields | |
$ (or C )
for character fields |
R
(the field automatically
takes the type of the original variable field).N
(numeric computed).
Note: For repeated fields, the first occurrence of
the field in the display is treated as the original field, the next occurrence
is treated as the first repeat, and so on.
FSEDIT Names Window Commands |
In addition to the global commands that are listed in SAS/FSP Software Global Commands, you can use the following commands in the FSEDIT Names window step to scroll through information, duplicate selected lines, and exit, going directly into the field identification step.
Scrolling
| |||||
Duplicating
| |||||
Other
|
Here are descriptions of the FSEDIT Names window commands:
Note: FSEDIT procedure windows share the same
KEYS entry. Changes that you make
with this command from the FSEDIT Names window will affect the other windows
also.
R
(repeated), you receive an error message warning you that
the copy is the second occurrence of the field name. To cancel the error,
change the name on the copied line.Exiting the FSEDIT Names Window |
When you have defined all computational and repeated fields, issue the END command to leave the field definition step. Once all special fields are defined to the procedure, you enter the field identification step, where you identify the locations of all special fields and any variable fields that the FSEDIT procedure has lost track of.
Step 3: Identifying Fields |
The FSEDIT Identify window is opened automatically when the FSEDIT Names window is closed, or when the FSEDIT Modify window is closed if no special fields were created during display modification. When the FSEDIT Identify window is opened, the status of each field, whether a data set variable field or a special field, is determined to be one of the following:
Before you can exit the field identification step, all fields must be either identified or defined as unwanted. When the FSEDIT procedure knows the location of all variable fields, the following message is displayed:
NOTE: All fields are identified.
If the FSEDIT procedure does not know the location of a variable field, or if you have added any special fields, you are asked to identify the location of the unidentified fields.
Unidentified Fields |
Fields in a customized display can become unidentified in several ways:
For each unidentified field, you receive a prompt like the following:
Please put cursor on field: name and press ENTER ... or UNWANTED
To indicate that you are not using a particular variable in the application, issue the UNWANTED command. To identify the location of a variable field or a special field that is being used in the application, position the cursor on any underscore in the appropriate field and press ENTER. Continue to identify fields until a message tells you that all fields are identified.
For example, if you receive the prompt
Please put cursor on field: ADDR1 and press ENTER ... or UNWANTEDyou can do one of the following:
Changing a Field from Unwanted to Identified |
If you change your mind about making a variable unwanted, you can use the DEFINE command. Follow DEFINE with the variable name; then position the cursor on the variable field and press ENTER.
If you want to change the status of several variables, you can use the WANTED command. When you issue the WANTED command without specifying any variable names, all unwanted variables become unidentified. The FSEDIT procedure then prompts you to identify the location of all unidentified variable fields.
Notice the difference between these two commands: DEFINE changes a single variable directly from unwanted to identified. WANTED changes one or all variables from unwanted to unidentified. You must then identify the location of each variable's field or define the variable as unwanted again.
FSEDIT Identify Window Commands |
In addition to the global commands that are listed in SAS/FSP Software Global Commands, you can use the following commands in the FSEDIT Identify window:
Identifying Fields
| ||||
Scrolling
| ||||
Other
|
Here are descriptions of the FSEDIT Identify window commands:
Note: FSEDIT procedure windows share the same
KEYS entry. Changes that you make
with this command from the FSEDIT Identify window also affect the other windows.
Exiting the FSEDIT Identify Window |
You cannot exit the field identification step until you have identified the locations of the fields for all wanted variables and have received the following message:
NOTE: All fields are identified.After receiving this message, you can issue the END command to close the FSEDIT Identify window and return to the FSEDIT Menu window.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.