Customizing the SIR Menu System Managing the Interactive SIR-RDBMS User Environment © Tom Shriver, DataVisor 2002.

Slides:



Advertisements
Similar presentations
The Web Warrior Guide to Web Design Technologies
Advertisements

FINAL REVIEW Carley. Contents Unit A: Understanding Essential Computer Concepts Unit B: Getting Started wit Mac OS X Leopard Unit C: Understanding File.
Visual Basic 2010 How to Program. © by Pearson Education, Inc. All Rights Reserved.2.
Guide to Oracle10G1 Introduction To Forms Builder Chapter 5.
Automating Tasks With Macros
A Guide to Oracle9i1 Introduction To Forms Builder Chapter 5.
Automating Tasks With Macros. 2 Design a switchboard and dialog box for a graphical user interface Database developers interact directly with Access.
A Guide to Oracle9i1 Creating an Integrated Database Application Chapter 8.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
Introduction To Form Builder
Digital Image Processing Lecture3: Introduction to MATLAB.
Chapter 8: String Manipulation
Programming with Microsoft Visual Basic th Edition
Visual Basic Chapter 1 Mr. Wangler.
Session 5: Working with MySQL iNET Academy Open Source Web Development.
| | Tel: | | Computer Training & Personal Development Outlook Express Complete.
Department of Mechanical Engineering, LSUSession VII MATLAB Tutorials Session VIII Graphical User Interface using MATLAB Rajeev Madazhy
Chapter 1: An Introduction to Visual Basic 2005 Programming with Microsoft Visual Basic 2005, Third Edition.
Copyright © 2007, Oracle. All rights reserved. Managing Concurrent Requests.
Chapter 5 Menus, Common Dialog Boxes, and Methods Programming in C#.NET © 2003 by The McGraw-Hill Companies, Inc. All rights reserved.
Processing SIRxs Journals Presented at SIR-UK Conference Dublin, Ireland, June 2008 © Tom Shriver, DataVisor 2008.
Domain 3 Understanding the Adobe Dreamweaver CS5 Interface.
XP 1 Microsoft Word 2002 Tutorial 1 – Creating a Document.
Converting SIR 3.2 Databases to SIR2002 A Practical Guide to Coming of Age in SIR Land © Tom Shriver, DataVisor 2002.
In the next step you will enter some data records into the table. This can be done easily using the ‘Data Browser’. The data browser can be accessed via.
JavaScript, Fourth Edition Chapter 5 Validating Form Data with JavaScript.
Chapter One An Introduction to Visual Basic 2010 Programming with Microsoft Visual Basic th Edition.
Basic & Advanced Reporting in TIMSNT ** Part Two **
Lesson 11: Looking at Files and Folders what a file or folder is on the computer how to recognize a file or folder on the desktop how to recognize the.
Diagnostic Pathfinder for Instructors. Diagnostic Pathfinder Local File vs. Database Normal operations Expert operations Admin operations.
Tutorial 51 Programming Structures Sequence - program instructions are processed, one after another, in the order in which they appear in the program Selection.
Chapter Two Creating a First Project in Visual Basic.
Creating Graphical User Interfaces (GUI’s) with MATLAB By Jeffrey A. Webb OSU Gateway Coalition Member.
Introduction to Enterprise Guide Jennifer Schmidt Rhonda Ellis Cassandra Hall.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 8 Debugging, Creating Executable Files, and Distributing a Windows Application.
A Baker's Dozen Tricks in a Button Thirteen Tricks of the SIR Trade Rolled into a Single Useful Application © Tom Shriver, DataVisor 2002.
Microsoft Office XP Illustrated Introductory, Enhanced Started with Windows 2000 Getting.
O FFICE M ANAGEMENT T OOL - II B BA -V I TH. Abdus Salam2 Week-7 Introduction to Query Introduction to Query Querying from Multiple Tables Querying from.
IBC233 Lecture 2 Updated Winter 2008 Agenda Test next Week – Jan 23 ISeries Architecture CL (Control Language) Library Lists Operations Navigator.
1 PL\SQL Dev Templates. 2 TEMPLATE DEFINITION Whenever you create a new program unit, its initial contents are based upon a template which contains pre-defined.
3 Copyright © 2004, Oracle. All rights reserved. Working in the Forms Developer Environment.
Copyright © Curt Hill More Components Varying the input of Dev-C++ Windows Programs.
GUI development with Matlab: GUI Front Panel Components GUI development with Matlab: Other GUI Components 1 Other GUI components In this section, we will.
Programming with Microsoft Visual Basic 2008 Fourth Edition Chapter Eight String Manipulation.
Copyright © 2015 Pearson Education, Inc. Publishing as Pearson Addison-Wesley C H A P T E R 13 GUI Programming.
Visual Basic for Application - Microsoft Access 2003 Programming applications using Objects.
Introduction to KE EMu
1.Introduction to SPSS By: MHM. Nafas At HARDY ATI For HNDT Agriculture.
Introduction to KE EMu Unit objectives: Introduction to Windows Use the keyboard and mouse Use the desktop Open, move and resize a.
SIRxs in Review aka The Joys of XS Presented at SIR-UK Conference Dublin, Ireland, June 2008 © Tom Shriver, DataVisor 2008.
Programming with Microsoft Visual Basic 2008 Fourth Edition Chapter Eight String Manipulation.
Microsoft Visual Basic 2008: Reloaded Third Edition Chapter One An Introduction to Visual Basic 2008.
Creating and Editing a Web Page
Creating and Editing a Web Page Using Inline Styles
Chapter 5 Introduction To Form Builder. Lesson C Objectives  Use sequences to automatically generate primary key values in a form  Create lists of values.
IE 411/511: Visual Programming for Industrial Applications Lecture Notes #2 Introduction to the Visual Basic Express 2010 Integrated Development Environment.
Visual Basic.NET BASICS Lesson 14 Menus and Printing.
Linux Administration Working with the BASH Shell.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
COMPREHENSIVE Excel Tutorial 12 Expanding Excel with Visual Basic for Applications.
Chapter 5 Validating Form Data with JavaScript
Running a Forms Developer Application
Working in the Forms Developer Environment
Topics Graphical User Interfaces Using the tkinter Module
Microsoft Access Illustrated
CIS16 Application Development Programming with Visual Basic
Windows xp PART 1 DR.WAFAA SHRIEF.
SIRxs in Review aka The Joys of XS Presented at SIR-UK Conference
Digital Image Processing
Using Templates and Library Items
Presentation transcript:

Customizing the SIR Menu System Managing the Interactive SIR-RDBMS User Environment © Tom Shriver, DataVisor 2002

Customizing the SIR Menu System Managing the Interactive SIR-RDBMS User Environment © Tom Shriver, DataVisor 2002

SIR Menus ©2002 Tom Shriver, DataVisor3 Interactive SIR as A Cascade of Events n SIR is Invoked with the Execution Statement oUsually an Icon on the Desktop oSets Various Defaults oMay have additional user startup specifications n SIR Starts oAt Least one PQL Program is Run: a Menu Definition oOther PQL and/or DBMS command sets may be run oLocal member SYSTEM.START runs as default before Menu n The User is Given Control of the Flow of Events oMay Use Action Elements in the Defined Environment oMay Change Operating Parameters oMay Modify the Interactive Environment

SIR Menus ©2002 Tom Shriver, DataVisor4 The SIR Environment u The Interactive SIR Environment is: n Controlled by PQL Programs oDefault Initial Program: SYSPROC.SYSTEM.MAINMENU oMainMenu Uses Subroutines defined in SYSPROC.MENU n Includes: oInitial Programs Executed at Log-On oPull Down Menus and Sub-Menus oTool Bar Buttons oThe Dialogs, Utilities and Listings Initiated by these Items n May be Customized

SIR Menus ©2002 Tom Shriver, DataVisor5 Typical Customizations n Set Up User Environment at Login oSet Global Variables oDefine Attributes oConnect Additional Databases n Add Options for Frequently Performed Actions oReports oStart Data Entry System oLocal Utilities n Restrict Users from Certain Standard Options oDisable Items: e.g. "Delete Database"

SIR Menus ©2002 Tom Shriver, DataVisor6 Factors Behind the Environment u Many Factors Play Roles in the Environment n PQL Routines: Take actions we specify n Global Variables: Pass info between procedures n File Attributes: Short names for files n Preferences: Set standard options like Editor n Recently Used Options, Files, etc

SIR Menus ©2002 Tom Shriver, DataVisor7 Where Factors are Defined u Various Repositories for Environment Settings n SIR.INI file oSIR Maintains many preferences like Editor to use oUser may keep and use things in SIR.INI n SIR Execution Statement oDatabase, Master and Tabfile Connections oSet Global Variables oExecute local startup member n Startup Member n Menu PQL Program

SIR Menus ©2002 Tom Shriver, DataVisor8 Customizing MainMenu u Several Strategies Available n Define custom menu program from scratch (a daunting task) Edit and Recompile SYSPROC.SYSTEM.MAINMENU (not recommended) Copy, Edit & Compile SYSPROC.SYSTEM.MAINMENU (the method we'll focus on here) n Use DVMenu (a GUI method)

SIR Menus ©2002 Tom Shriver, DataVisor9 Copy SIR's MainMenu as a Starter 1. Set procfile: SYSPROC ( \SIR2002\SIRPROC.SRP ) use browse button on Members Dialog 2. PWRITE SYSPROC.SYSTEM.MAINMENU 3. Set Procfile back to Default Procfile 4. PREAD the PWRITE n file

SIR Menus ©2002 Tom Shriver, DataVisor10 Set Up Local MainMenu as Default 1. Edit SYSTEM.MAINMENU, change third line. PROGRAM SAVE=SYSPROC.SYSTEM.MAINMENU /REPLACE /NOEXECUTE to PROGRAM SAVE=SYSTEM.MAINMENU /REPLACE /NOEXECUTE 2. Run SYSTEM.MAINMENU 3. Create New Member SYSTEM.START program get=system.mainmenu:e end program 4. Exit SIR and Re-Start You are now running your own Menu, not SIR's

SIR Menus ©2002 Tom Shriver, DataVisor11 Understanding VisualPQL Menu Programming  PQL Menu System defined with a WINDOW block WINDOW has BUTTON and MENU ITEM Definitions n Each Item is Given a Numeric Identifier  WINDOWS are Message Processing Systems WINDOW block contains a MESSAGE block Think of Message Block as a "Process Message" n Each User Action Generates a Message MESSAGE command sets a PQL variable with the Item Identifier to indicate which item generated the message

SIR Menus ©2002 Tom Shriver, DataVisor12 Structure of a PQL Menu Program PROGRAM WINDOW. MENU menu_label. MENUITEM item_id#, item_label, hotkey, checkable. END MENU. TBARITEM item_id#, button_picture, tip_text, checkable. INITIAL | special message block, executes once when first started. pql_commands to start things off. END INITIAL. MESSAGE COMMAND id_var | this variable updated with item#'s. IF(id_var eq item#)pql_command | logic & what to do when given item clicked. IF(id_var eq 0)EXIT MESSAGE | item zero is always "Quit". END MESSAGE END WINDOW END PROGRAM

SIR Menus ©2002 Tom Shriver, DataVisor13 Additional Menu Commands MENU Block Commands o MENUSEP provides horizontal rule in menu list o TBARSEP provides a bit of space between buttons n Item Control Commands o CHECK MENUITEM o UNCHECK MENUITEM o DISABLE MENUITEM o ENABLE MENUITEM n Flow Control o NEXT MESSAGE o EXIT MESSAGE

SIR Menus ©2002 Tom Shriver, DataVisor14 A Few More Menu Commands n Window Control Commands o WINDOW CLEAR o WINDOW SAVE file_name o WINDOW TITLE "text" | string_var o WINDOW STATUS LINE "text" | string_var o WINDOW OUTPUT "text" | string_var n Additional Message Blocks INITIAL END INITIAL DROPFILE file_name_var END DROPFILE

SIR Menus ©2002 Tom Shriver, DataVisor15 Conventions Used by SIR in MainMenu n Menu & ToolBar Item IDs defined with "Aliases" Alias is a declared integer variable with meaningful name that is assigned a value INTEGER * 4 EXIT DELETEDB LISTSTAT UNLOAD PRESET EXIT DELETEDB LISTSTAT UNLOAD (0,1,2,3) MENUITEM LISTSTAT, '&List Stats','l', 0 Message Command ID Variable is: ID MESSAGE COMMAND ID IFTHEN(ID EQ LISTSTAT). EXECUTE DBMS "LIST STATS" ;NEXT MESSAGE ENDIF END MESSAGE

SIR Menus ©2002 Tom Shriver, DataVisor16 EXECUTE DBMS The PQL Command that Makes it all Possible u The "Suspend and Execute" Command 1. Suspends current operation (PQL program) 2. Opens a new, deeper "Operating Level" 3. Executes a DBMS Command at this deeper level 4. Returns to higher level when done and resumes the suspended PQL program  Illegal in RETRIEVAL and SUBROUTINE DATABASE and FORM  Use in PROGRAM only

SIR Menus ©2002 Tom Shriver, DataVisor17 EXECUTE DBMS Syntax and Usage u Syntax EXECUTE DBMS "text" | string_var u Usage Examples IF(ID=REP_01)EXECUTE DBMS "CALL REPORTS.COSTS" COMPUTE FILENAME=TRIM(VALLAB(CITY))+".DAT" COMPUTE CMD="EDITFILE '"+FILENAME+"'" EXECUTE DBMS CMD

SIR Menus ©2002 Tom Shriver, DataVisor18 Customizing Your Menu Deleting / Disabling SIR Options u Removing Menu & ToolBar Items 1. Edit your MainMenu 2. Find item to delete (search for label) 3. Delete MENUITEM or TBARITEM command u Disabling Menu & ToolBar Items 1. Edit your MainMenu 2. Find alias name of item 3. Find SUBPROCEDURE CHECKDB (executed each cycle) 4. Just before END SUBPROCEDURE, insert DISABLE MENUITEM commands, e.g. DISABLE MENUITEM DELETEDB

SIR Menus ©2002 Tom Shriver, DataVisor19 Customizing Your Menu Adding New Options 1. Create a member that does what you want. Make sure it runs correctly. 2. Edit Local MainMenu 1.Add a Unique Alias to Data Declarations 2.Assign a Value to the Alias (suggest 8000+) 3.Create a Pull Down Menu ( MENU command) if needed. Placement relative to SIR MENU s determines position 4.Insert MENUITEM and TBARITEM commands 5.Insert Booleans with EXECUTE DBMS command, e.g. IF(ID EQ MYREP)EXECUTE DBMS "CALL REPORTS.MYREP"

SIR Menus ©2002 Tom Shriver, DataVisor20 ToolBar Buttons Special Considerations u Button Images have special Requirements Image must be a BitMap File ( *.BMP ) Image must be exact size: 21 x 21 pixels Image must be in the SIR TBBB folder, e.g. c:\sir2002\tbbb\dvmenu.bmp

SIR Menus ©2002 Tom Shriver, DataVisor21 Customizing Your Menu Window Title Bar Text WINDOW TITLE command executed twice oFirst Command in WINDOW block oIn SUBPROCEDURE CHECKDB SIR constructs title string using variables it maintains: SIRTITLE taken from SIR.INI DBNAME current default db name MASTNAME name of master if in use WINDOW TITLE [sirtitle+' '+DBNAME+MASTNAME] To customize, change WINDOW TITLE in CHECKDB, e.g. WINDOW TITLE [sirtitle+' '+MASTNAME+' '+dsn('SIR011')]

SIR Menus ©2002 Tom Shriver, DataVisor22 Kicking it Up a Notch u Problem with Copying & Editing MainMenu When SIR sends a new SYSPROC, you have to do all the work all over again. u Solution: Make Your Specifications CALL able Members, e.g. MENUS.DATADEFS for data declarations & presets MENUS.MENUOPS for Menu & Button definitions MENUS.MNUEXECS for logic and execution cmds MENUS.WINTITLE for Window Title construction MENUS.DISABLE to disable SIR Items

SIR Menus ©2002 Tom Shriver, DataVisor23 Kicking it up a Final Notch DVMenu: a GUI Menu Manager u DVMenu Implements these Principles n A GUI Front End Creates and Saves CALL able Members A Program to Insert CALL s into SYSPROC MainMenu n Then it compiles new MainMenu n Then prompts user whether to quit and restart u Main Advantages n Always based on most current SIR MainMenu n Ease of Use, lots of point and shoot choices