NOMAD Sample Window Code Version 5.8 DISCLAIMER These samples are excerpts from the sample code originally presented as part of the 1987 Users' Conference, and subsequently made an unsupported portion of the NOMAD Collection. These procedures are intended as SAMPLES, not TOOLS. They are offered on an AS-IS basis. WMLIST Provide a POP-UP window with a list of the currently loaded database MASTERS. Pressing enter closes the active window and exits WMLIST. Available functionkey actions include: FKEY 2 - CALL WILIST for master where cursor is positioned. FKEY 3 - Reposition window to current cursor position, leave window open, and exit WMLIST. FKEY 7 - Scroll up. FKEY 8 - Scroll down. WILIST -segmentname- Provide a POP-UP window with a list of the ITEMS and DEFINES for the segment reference. Pressing enter closes the active window and exits WILIST. Available functionkey actions include: FKEY 7 - Scroll up. FKEY 8 - Scroll down. FKEY 3 - Reposition window to current cursor position, leave window open, and exit WILIST. WPICK 'title' 'choice1' 'choice2' ... 'choice-n' Provide a pop-up window with a list of choices. The TITLE and CHOICE strings may be strings or &variables. The choice may be an &variable array. WCLOCK Provide a passive data display window with the current date and time. The first call opens it, the next closes it. WMONITOR Provide a passive data display window with &&ARU's, &&INSTANCE_COUNT, and TOT_CPU. The first call opens it, the next closes it. WFORM segment-name WFORM will build a form-based window for all the items in the specified segment. This form will exist only for this session; no permanent source code is generated. RMAINT RMAINT is a sample update procedure for a single master. It updates the master in the NAMES database. Available functionkey actions include: FKEY 2 - Insert an Instance. FKEY 3 - Quit. FKEY 4 - Locate an Instance. FKEY 5 - Change Instance data. FKEY 6 - Delete Instance. FKEY 7 - Previous Instance. FKEY 8 - Next Instance. FKEY 9 - First Instance. FKEY 10 - Last Instance. FKEY 12 - Cancel Current action. FKEY 13 - Help. (See WTUPDATE in another directory of this diskette for a tool which generates update procedures somewhat similiar to this). WPUSH WPUSH closes all currently open windows, saving a list of them for later opening by WPOP. WPOP WPOP will open the list of windows closed by WPUSH. WASK question Ampervariable WASK creates a window-based prompt for an ampervariable. WEZHELP <FORM> <FIELD> <SENSE> <KEYVAL> WEZHELP is identical to EZHELP as provided with the NOMAD Collection. Please reference the NOMAD Collection Guide for further usage notes. WEZHELP calls WEZHELPR, which has been updated to provide a Pop-Up window for displaying and optionally entering the help data. WSTICKY field form WSTICKY will build a pop-up menu of values for a field with a MEMBER integrity check. ON MEMBER DO ; CALL WSTICKY &&MEMBER &&CURSORFORM ; RETURN ; END ; WCOURSES WCOURSES updates the COURSES 3-level hierarchy using cascaded windows. Form-based windows are created for each segment in the hierarchy using WFORM. WCASCADE is used to cascade the forms. Available functionkey actions include: FKEY 2 - Toggle Active Segment. FKEY 3 - Quit. FKEY 7 - Previous Instance. FKEY 8 - Next Instance. WCASACDE array-name WCASACDE will take a list of window names and open the windows in a cascaded fashion. WLZOOM WLZOOM demonstrates the idea of ZOOMing LIST requests. In other words, present the user with a summary LIST request, allow them to point to a specific summary item in the LIST, and then generate another LIST request at a higher level of detail. Available functionkey actions include: FKEY 13 - Help. FKEY 2 - Summary Report. FKEY 3 - Detail Report. FKEY 7 - Scroll Up current Window. FKEY 8 - Scroll Down Current Window. WDUMP < window-name < name < type >>> WDUMP will dump the contents of a TEXTUAL window to a file/ dataset. WPROC <procname> WPROC allows a user to build and execute a NOMAD procedure from within a textual window. This removes the distinction between "interactive" and "procedural" commands. In other words, a user can enter ANY NOMAD command and have it executed immediately, without the need to create a NOMAD procedure. WPOPUP window-name WPOPUP will build a textual window and add all the behaviors necessary for "POP-UP" behavior.