ebook img

Programming Rational System Architect with VBA PDF

221 Pages·2009·2.11 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Programming Rational System Architect with VBA

IBM Rational System Architect VBA Extensibility Guide Release 11.3 Before using this information, read the “Notices” in the Appendix, on page 20-1. This edition applies to IBM® Rational® System Architect®, version 11.3 and to all subsequent releases and modifications until otherwise indicated in new editions. © Copyright IBM Corporation 1986, 2009 US Government Users Restricted Rights—Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Table of Contents T a b l e of C on t en t s Table of Contents ....................................................................................................... i Introduction ............................................................................................................ 1-1 Automating Rational System Architect ...................................................... 1-2 Programming Rational System Architect with VBA .................................. 1-3 Running a Macro .......................................................................................... 1-4 Macro Projects .............................................................................................. 1-5 Accessing the VBA Editor ............................................................................ 1-7 Object Browser ............................................................................................ 1-11 Automation and Rational System Architect ................................................... 2-1 Automation ................................................................................................... 2-2 Customizable Solutions ................................................................................ 2-7 Planning an Automated Solution with Rational System Architect ........... 2-9 The Application Class ........................................................................................... 4-1 Attributes ...................................................................................................... 4-3 Methods ......................................................................................................... 4-5 The Encyclopedia Class ........................................................................................ 5-1 Attributes ...................................................................................................... 5-3 Methods ......................................................................................................... 5-6 Relation Metrics.......................................................................................... 5-20 The Diagram Class ................................................................................................. 6-1 Attributes ...................................................................................................... 6-3 Methods ......................................................................................................... 6-9 Diagram Fields ........................................................................................... 6-20 Diagram Metrics ......................................................................................... 6-26 The Symbol Class ................................................................................................... 7-1 Attributes ...................................................................................................... 7-3 Methods ....................................................................................................... 7-14 Symbol Fields .............................................................................................. 7-23 i Table of Contents Symbol Metrics ........................................................................................... 7-31 The Definition Class .............................................................................................. 8-1 Attributes ...................................................................................................... 8-3 Methods ......................................................................................................... 8-8 Definition Fields ......................................................................................... 8-15 Definition Metrics ....................................................................................... 8-17 The MetaModel Class ............................................................................................ 9-1 Attributes ...................................................................................................... 9-2 The MetaClass Class ............................................................................................ 10-1 Attributes .................................................................................................... 10-2 The MetaItem Class ............................................................................................. 11-1 Attributes .................................................................................................... 11-2 The MetaProperty Class ..................................................................................... 12-1 Attributes .................................................................................................... 12-3 The MetaKeyedBy Class ..................................................................................... 13-1 Attributes .................................................................................................... 13-2 Rational System Architect Collections ........................................................... 14-1 SAObjects Class .......................................................................................... 14-3 SACollection Class ...................................................................................... 14-6 OfCollection Class ...................................................................................... 14-8 Rational System Architect Events ................................................................... 15-1 Application Events ..................................................................................... 15-2 Guidelines for Adding Macro Items to Menus Programmatically ........... 15-9 Rational System Architect Relationships ...................................................... 16-1 Relation Types ............................................................................................ 16-2 Rational System Architect Field Types .......................................................... 17-1 Field Types .................................................................................................. 17-2 Rational System Architect Errors ................................................................... 18-1 Handling Errors.......................................................................................... 18-2 Rational System Architect Errors ............................................................. 18-3 IBM Support .......................................................................................................... 19-1 Contacting IBM Rational Software Support ............................................. 19-2 Appendix ................................................................................................................ 20-1 Notices ......................................................................................................... 20-2 Table of Contents Trademarks ................................................................................................. 20-5 iii 1 In t r od u c t i on Introduction This chapter covers the fundamentals of working with Rational System Architect and Visual Basic for Applications (VBA). You will learn about using macros, the VBA Editor, and the Object Browser. Topics in this chapter Page Automating Rational System Architect 1-2 Programming Rational System Architect with VBA 1-3 Running a Sample macro 1-4 Macro Projects 1-5 Accessing the VBA Editor 1-7 Object Browser 1-11 1-1 Introduction Automating Rational System Architect Rational System Architect is ‘VBA enabled’ allowing the user to control the Rational System Architect environment programmatically, and to control other applications using OLE automation. Microsoft VBA and its development environment are installed with Rational System Architect. The programming environment, debugging environment, language and help system are the same as found in other VBA enabled applications, including Microsoft Office products. Using automation, you can integrate other applications with Rational System Architect in the two ways. You can use Rational System Architect: As an automation controller, and call an OLE automation object from within a Rational System Architect script. As an automation server, and call its OLE automation object from within another OLE-compliant application. Macros within Rational System Architect can be used to: Enhance the functionality of Rational System Architect – automating the presentation and rules checking of diagrams. Create diagrams, symbols and definitions from information contained in other applications. Capture events that take place in Rational System Architect and store them in a file or database. 1-2 Programming Rational System Architect with VBA Programming Rational System Architect with VBA Rational System Architect stores the current status of its VBA project environment in the initialization file SA2001.INI, (found in either the Windows or WinNt folder). The section entitled Macros may contain the following: [Macros] PermanentAutoLoad1=SAAuto.mac TemporaryAutoLoad1= c:\program files\ibm \system architect suite\system architect\sample.mac|vxRead|vxShared|vxTransacted|b ProjectActive RunTemporaryAutoMacros=T OpenReadOnly=T The above excerpt indicates that the permanent SAAUTO.MAC project file is loaded when Rational System Architect starts. (It will be hidden and read-only). The temporary SAMPLE.MAC project file is currently active and is also loaded in read-only mode. If any of the temporary project files contain an AutoExec module, then the macros are automatically executed. The default for opening new projects will be Read Only. 1-3

Description:
VBA Extensibility Guide. Release .. You will learn about using macros, the VBA Editor, and the .. Conversion manual found on the IBM support site.
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.