BROWSER.EXE

Overview

This is a graphical mode application that implements a browser for SMS objects. The program allows you to configure and apply filters to the containers that you open. You can view the containers, folders, subfolders, and scalars with this program.

Running the Program

    To run BROWSER.EXE
  1. Connect to the appropriate datasource by supplying the SQL Server name, Database name, SQL Logon ID, and Password.
  2. Select a container to browse.
  3. Select the filters you want to apply (if any). If you do not apply any filters, then you will see all objects in the container when you view it. Multiple filters may be selected for the container. Note that you will not be able to select any filters until you have specified the container.
  4. If you select any filters, you must configure them by clicking Configure Filter and setting tokens into the specified filter. There are currently eight filters available: Site, Machine, Group, Job, Architecture, Package, SiteLimit, and Attribute. Machine filters require a group class, an attribute name, an operator, and a value; other filters do not need the group class field. The dialog box will automatically enable the correct edit fields based on the filter type you select.
  5. View the selected container dialog box by clicking View Container at the lower part of the dialog box. This dialog box displays the container type, the number of folders contained in the container, and a list of these folders. Note that you will not be able to view the container until you have selected and configured the filters.
  6. Select and view a folder by clicking View Folder.
  7. View the folder scalars or subfolders by clicking the appropriate buttons. Click Back to return to the previous dialog box. Click Done to dismiss this dialog box and return to the main dialog box. Quit the browser by clicking Quit, or restart by clicking Connect.

Functions

This sample application illustrates possible uses of the following SMS functions:

SmsDataSourceConnect
SmsDataSourceDisconnect
SmsEnumContainers
SmsOpenContainer
SmsPopulate
SmsCloseContainer
SmsGetNextFolder
SmsCloseFolder
SmsRewind

SmsGetFolderID
SmsGetFolderType
SmsGetFolderCount
SmsEnumFolderTypes
SmsGetScalarCount
SmsGetNextScalar
SmsEnumFilters
SmsCreateFilter
SmsCloseFilter
SmsGetAllFilters
SmsGetFilterType
SmsGetToken
SmsAddToken
SmsGetTokenCount

Program Flow

This sample application uses the SmsEnumContainers and SmsEnumFilters functions to discover the containers and filters that have been registered with the datasource. The resulting strings are used to populate the list boxes for the containers and filters.The program allows the user to log on to the database and to select a container to browse. The program opens the container with SmsOpenContainer and then uses the SmsEnumFilter functions to create and configure any filters the user selects. The program then displays the contents of the container to the user. The user can also view any folder that is contained within the container hierarchy. A folder is logically composed of three entities:

  1. Details about the folder itself (see the Folder Details section of the View Folder dialog box).
  2. Subfolders (click View Subfolder in the Subfolders section of the View Folder dialog box).
  3. Scalars (click View Scalars in the Folder Details section of the View Folder dialog box).