地理信息系统开发工具GISDK使用手册英文版第三部分CreatingGISDKMacros.doc
《地理信息系统开发工具GISDK使用手册英文版第三部分CreatingGISDKMacros.doc》由会员分享,可在线阅读,更多相关《地理信息系统开发工具GISDK使用手册英文版第三部分CreatingGISDKMacros.doc(234页珍藏版)》请在沃文网上搜索。
1、Creating GISDK Macros1 GISDK Mechanics31.1 Compiling Resources41.2 Working with the GISDK Debugger121.3 Installing GISDK Applications19Installing and Running Add-Ins20Installing and Running Custom Applications201.4 Accessing TransCAD as a COM Object251.5 Accessing TransCAD Matrices from FORTRAN Prog
2、rams442 Language Elements532.1 Language Elements532.2 Variables542.3 Types552.4 Variable Scope642.5 Function Calls662.6 Statements692.7 Error Handling753 Resources763.1 Macros773.1.1 Macro Arguments773.1.2 Macro Return Values783.1.3 Functions for Macros793.2 Dialog Boxes793.2.1 Dialog Box Arguments8
3、03.2.3 Dialog Box Return Values813.2.4 Position813.2.5 Options823.2.6 Dialog Box Items833.2.7 Tab Order983.2.8 Functions for Dialog Boxes993.3 Toolboxes993.3.1 Tool Items1003.3.2 Update Item1023.3.4 Close Item1033.4 Toolbars1033.5 Menus1044 Standard Interface Macros107Annotation Font109Annotation Se
4、lect109Annotation Text110Call Menu Item110Create Legend110File Close All111Layer Settings111Layer Status112New Layer Default Settings112Scale for Layer113Setup Colors113Setup Colorsplay114Setup Fill Styles114Setup Fillsplay114Setup Line Styles115Setup Linesplay115Setup Palettes116Setup Quantile Fill
5、styles117Update Map Toolbar117Set Exist117Create Set118Delete Set118Locate View118Locate Address121Locate Address Results122Address Match124Get Rule Files125Get City Rule Files126Get Location Index Properties126Get Location Index127Find with Location Index128Drop Location Index130Drop All Location I
6、ndexes131Locate View131Location Index Example133Set Default Route System Style136Set Network136You write GISDK macros and other resources, including dialog boxes and menus, using Caliper Script, a programming language that provides full access to GISDK functions in the platform. Resources are compil
7、ed into a database, called a UI Database. This section describes the mechanics of creating UI Databases, the language elements in Caliper Script, and the types of resources that you can write. Also described are the GISDK Debugger and accessing TransCAD as an Automation Server.For more information,
8、see.GISDK Mechanics Language Elements Resources 1 GISDK MechanicsGISDK provides a powerful means for creating, testing, and installing add-ins, custom applications, and server applications. This section contains technical information on GISDK and how it works, including essential reference informati
9、on.For more information, see.The Platform and the UI DatabaseCompiling ResourcesWorking with the GISDK Debugger Installing GISDK ApplicationsAccessing TransCAD as an Automation Server The Platform and the UI DatabaseTo a user, TransCAD is a program like any other Windows program. To a GISDK develope
10、r, however, TransCAD has two distinct parts: the platform and the user interface (UI). The platform is the core set of geographic information system (GIS) and database management system (DBMS) capabilities that are used to make maps and perform analysis.The user interface (UI) is the set of menus, d
11、ialog boxes, toolbars, and toolboxes that provide a user with access to these capabilities, along with the GISDK instructions that are followed when a menu item, toolbar, toolbox, or dialog box option is chosen.The platform is contained in the executable program file (tcw.exe) and the various dynami
12、c link libraries (DLLs) and other files that support it. The UI is stored in a database, called the UI Database. The UI Database for TransCAD is named gis_ui and contains the following files: gis_ui.dbd, gis_ui.1, gis_ui.2, gis_ui.3, gis_ui.4, gis_ui.5, and gis_ui.6. The platform and the UI Database
13、 are inseparable - each one is useless without the other.When you create GISDK applications, you create your own UI Databases. When you run an add-in or custom application, you are combining the platform with your own UI Database. You choose the UI Database you want to use when you install an add-in
14、 or custom application, or by modifying the command line that starts the platform.1.1 Compiling ResourcesWhen you write GISDK programs, they are stored in ordinary text files that are known as resource files. Resource files always have an extension of .rsc. Because Caliper Script is a compiled langu
15、age, the programs you write must be compiled before they can be run. The program that compiles the resources is known as the resource compiler. The compiled resources are stored in a UI Database. Here is a flow chart that shows the relationship between resources, the resource compiler, the UI Databa
16、se, and the platform. The resource compiler can compile a single resource file, or a group of files, at one time. To compile a group of files, you create a list file. A list file is a text file with an extension of .lst that contains the names of all the resource files in your GISDK application, one
17、 per line.The resource compiler checks resource files as they are compiled for various types of errors, including errors in syntax, invalid statements, and mismatched do-end statements. If errors are detected, the resource compiler creates an error file listing each error and the line number at whic
18、h it was detected. The error file has the same name as the resource file and an extension of .err, and is always placed in the same folder as the resource file itself.GISDK includes several versions of the resource compiler. You can choose to compile resource files using:The buttons in the GISDK too
19、lboxThe rscc.exe program from DOS or WindowsLoadResourceFile() from within your own GISDK applicationFor more information, see.Compiling and Testing with the GISDK ToolboxCompiling with the Stand-Alone Resource CompilerCompiling with LoadResourceFile()User-Defined Compilation FlagsCompiling and Test
20、ing with the GISDK ToolboxThe GISDK toolbox is an add-in that contains tools you use to compile and test GISDK applications:ToolFunctionCompile resource file(s) to the default UI DatabaseTest a macro or dialog boxCompile resource file(s) to a stand-alone UI DatabaseStart the GISDK DebuggerExecute on
21、e or more Caliper Script statements immediatelyWhen you installed TransCAD, the GISDK Toolbox add-in was added to the add-ins.txt file, just like any other add-in.The button in the GISDK Toolbox compiles resources into a UI Database named test_ui. When you compile a resource file (or several resourc
22、e files in a list file) using the button, first the test_ui database is cleared, and then the compiled resources are added to that database.The button in the GISDK Toolbox tests a resource that you compiled into the test_ui database. You specify the name of the resource to run, and whether it is a m
23、acro or a dialog box.The button in the GISDK Toolbox lets you choose the UI Database in which to store the compiled resources. The database you choose is cleared, and then the compiled resources are added to the database. The button in the GISDK Toolbox starts the GISDK Debugger, which helps you fin
- 1.请仔细阅读文档,确保文档完整性,对于不预览、不比对内容而直接下载带来的问题本站不予受理。
- 2.下载的文档,不会出现我们的网址水印。
- 3、该文档所得收入(下载+内容+预览)归上传者、原创作者;如果您是本文档原作者,请点此认领!既往收益都归您。
下载文档到电脑,查找使用更方便
20 积分
下载 | 加入VIP,下载更划算! |
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 地理信息系统 开发 工具 GISDK 使用手册 英文 第三 部分 CreatingGISDKMacros