Chapter Contents

Previous

Next
SAS Companion for the Microsoft Windows Environment

Customizing the Toolbar

The SAS System assigns several commonly used commands to the toolbar icons for your convenience. You might find that the commands you use most often are different than the ones assigned to the toolbar by default. Or, you might want to create a toolbar to use with a specific application window or SAS/AF program. This section describes how to customize the toolbar settings.

You customize all toolbar settings using the Customize tools dialog box. To open the Customize tools dialog box, select the Tools menu and then select Customize.... You use the Toolbars page for general toolbar settings. You use the Customize page to define tools on the toolbar.


Setting General Toolbar Preferences

The Toolbars page lets you specify options that control the behavior and appearance the toolbar. Tools options include:

General
specifies toolbar button appearance and help options. These options include:

Large icons
specifies whether to use the set of large tool icons on the toolbar. This is especially useful for high-resolution displays.

Show ScreenTips on toolbars
specifies whether to display a short description of the toolbar button when you place the cursor over the toolbar button.

Toolbars
specifies whether or not to display the toolbar and command bar. These options include:

Application Toolbar
specifies whether to display the toolbar for the active application.

Command Bar
specifies to display the command bar and enable the options to use the command bar.
When Use AutoComplete is selected, SAS remembers previously entered commands and completes entering the command once you start typing the command.
Select Sort commands by most recently used to display commands in the command bar drop down list by the most recently entered command.
In the Number of commands saved box, enter the number of commands to save to display in the command bar list box. Valid values range between zero and 50. The default is 15.

When you have configured the Toolbars page, either click on Customize to complete your customization or click on [OK] to close the dialog box.


Customizing a Toolbar

The Customize page allows you to add, delete, and modify commands on the toolbar. Customize Page of the Customize Tools Dialog Box shows the Customize page of the Customize Tools dialog box.

Customize Page of the Customize Tools Dialog Box

[IMAGE]

You may recognize some icons as standard Windows icons, such as the OPEN and SAVE commands. The following list explains each of the icons (commands) and fields:

Commands that act on the file containing the toolbar definition are a series of three icons at the top of the page. From left to right:
the open icon opens a toolbar file
the save icon saves a toolbar file
the restore icon restores a toolbar to the default settings

Title
displays the title of the toolbar which displays as the window title when the toolbar is undocked.

Commands to define a toolbar are a series of eight icons that act upon the toolbar. From left to right:

Add a tool
adds a command or a separator space to the toolbar. To add a tool or a separator, click on the icon and select either Blank tool or Separator. Windows that define an action set (for example, Explorer) will have a selection for Action.

Remove tool
deletes a highlighted command in the toolbar list box from the toolbar.

Change icon
opens the Bitmap Browser to select a new icon for a command.

Move tool up
moves a command up one position in the toolbar list box.

Move tool down
moves a command down one position in the toolbar list box.

Cut
deletes the currently selected icon from the toolbar list box and places it in the clipboard.

Copy
places a copy of the selected icon to the clipboard.

Paste
copies an icon from the clipboard to the highlighted command in the toolbar list box.

Command
displays the command for the highlighted command in the toolbar list box. You can then add or modify the SAS command in the text box.

Help Text
display the help text that appears in the status bar when the cursor is placed over the icon in the toolbar. You can add or modify the help text in the text box.

Tip Text
displays the tip text that appears under the icon when the cursor is placed over the icon in the toolbar. You can add or modify the tip text in the text box.

Toolbar list box
lists the icons, commands, help text and separators defined in the toolbar.

When complete, click on [OK].


To Add a Tool to the Toolbar

To add a tool to the toolbar, perform the following steps:

  1. Do one of the following:

  2. Click on the Bitmap Browser icon. Select an icon in the Bitmap Browser dialog box, shown in Bitmap Browser Dialog Box, and click on [OK].

  3. Enter text in the Help Text field that will appear on the status line when you select the tool from the toolbar.

  4. Enter text in the Tip Text field that appears under the icon when you place the cursor over the icon.

  5. Position the tool in the tool list by clicking on Move Up and Move Down icons.

  6. When you are finished, click on the Save icon. In the Save Tools dialog box, enter the library, catalog, and toolbox name. Then click on [OK].

Bitmap Browser Dialog Box

[IMAGE]


Removing a Tool from the Toolbar

To remove a tool from the toolbar, select the tool you want to remove in the toolbar list box. Click on the Remove Tool icon. When you are finished, save the toolbar by clicking on the Save icon.


Customizing and Saving a Toolbar for Use with a Particular Application or Window

  1. Customize the toolbar by adding and removing tool icons as described above.

  2. When you are finished customizing the toolbar, click on the Save icon. The Save Tools dialog box appears (as shown in Save Tools Dialog Box).

  3. In the Save Tools dialog box, type in the libref, catalog, and entry information indicating where you want to store the toolbar information. If you want to associate this toolbar with a particular application or window, use the same library, catalog, and entry name as the PMENU entry for the window or application. For example, to store a customized toolbar for the graphics editor, you would save the tool settings in SASHELP.GI.GEDIT.
    CAUTION:
    If you save tool settings to the SASHELP library, you might overwrite the SAS-supplied tool settings; therefore, you would not be able to restore the SAS-supplied default settings.   [cautend]
    You can also store tool settings in the SASUSER.PROFILE catalog using the same entry name as the PMENU entry for the window or application. SAS first looks for toolbox entries in SASUSER.PROFILE before searching the application catalog.

    You can automatically assign the toolbar to the active window by clicking the Save tools for window check box. When you are finished, click on [OK].

Save Tools Dialog Box

[IMAGE]

If you save the toolbar so that it is associated with a particular application, SAS automatically loads the tools when that application's window is active.

You can use the TOOLLOAD command to load your custom toolbar manually. For more information about the TOOLLOAD command, see TOOLLOAD.


Resetting the Tools to the Default Settings

Click on the Restore Defaults icon. The SAS System asks you to confirm that you want to restore to the default tool settings. When you click on Yes, the tools are reset to their original settings (the settings that were in place when the SAS System was installed).

If a SAS application defines a default toolbar for its application window, clicking on the Restore Defaults icon restores the settings for that toolbar.


Examples of Useful Tools You Can Create

Suppose you want to create a tool that opens the SAS online documentation on the CD-ROM (SAS OnlineDoc). You would perform the following steps:

  1. In the Customize page of the Customize Tools dialog box, click on the Add tool icon. This creates a template for a new tool in the tool list.

  2. In the Command field, type SASDOC ONLINEDOC which is the command for invoking the SAS OnlineDoc product. For more information about Windows-specific SAS commands and their options, see SAS Commands under Windows. For information about portable SAS commands, refer to SAS online Help.

    In the Help Text field, type Open the SAS OnlineDoc. In the Tip Text field, type SAS OnlineDoc.

  3. Click on the Bitmap Browser icon. From the Bitmap Browser dialog box, select a bitmap appropriate for the help action (such as the help bitmap) and click on [OK].

  4. Use Move Up and Move Down icons to move the tool to its desired location on the toolbar or toolbox.

  5. Click on Save to save the tool with your default tool configuration.

The following are some examples of other tools that you might find useful to create:

PGM; CLEAR; INCLUDE C:\SAS\MYPROGRAM.SAS
includes a program that you use often into the Program Editor window for editing.

PGM; FILE C:\SAS\MYPROGRAM.SAS; CLEAR
saves a SAS program after you finish editing it and clears the Program Editor window.

PGM; CLEAR; INCLUDE C:\SAS\MYPROGRAM.SAS; SUBMIT
includes and submits a SAS program that you use often.

PGM; CLEAR; INCLUDE C:\SAS\SIGNON.SAS; SUBMIT
includes and submits a SAS program to sign on to a remote system. For example, to sign on to a remote MVS session, the SIGNON.SAS program might contain:

options comamid=ehllapi remote=mytso;
libname remtdata 'mylib.mydata.monthly';
signon;
For more information about signing on to remote sessions, see SAS/CONNECT User's Guide.

PGM; CLEAR; INCLUDE C:\SAS\DOWNLOAD.SAS; SUBMIT
includes and submits a SAS program to download a data set from a remote session. Assuming that you have already signed on to the remote session, DOWNLOAD.SAS might contain:

proc download data=remtdata.june;
   /* where libname 'remtdata' is */
   /* already defined             */
run;
For more information about signing on to remote sessions, see SAS/CONNECT User's Guide .

TOOLLOAD BAR SASUSER.PROFILE.MORTOOLS
loads a different toolbar (that you created) containing another collection of tools.


Chapter Contents

Previous

Next

Top of Page

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.