From the Crow's Nest, on the banks of the Tennessee River, in beautiful Athens, Alabama, we bring you tools and tips that we hope will make working in FRAMME a little more organized and enjoyable for you...
Please support the FRAMME community by sharing your ideas with us. Everyone is stronger when we work together! Email your submissions to the Crow's Nest here.
FRAMME Programming Utilities (8)
FRAMME with MicroStation MDL (3)
FRAMME with Visual Basic (6)
FRAMME ODL Source Code (3)
FRAMME User Group Presentations (2)
FRAMME Tips and Tricks (6)
Check back for regular updates ...
This MDL application illustrates how to apply a MicroStation command filter in a FRAMME session that disables certain MicroStation commands from being executed from the command line. In the example source, the MicroStation delete functions are disabled so users are forced to delete FRAMME features using the FRAMME commands (and thus ensuring the deletes can be posted to the master model). If the user enters an invalid MicroStation command, the filter stops execution of the command and issues an appropriate error message.
This MDL application enhances the standard Zoom In, Zoom Out, and Window Area functions such that the view is
automatically "decluttered". When the operator uses one of these commands to define a view, the function
calculates the scale of the new view and automatically turns levels on and off based on the scale. Typically, when
zoomed in very close, the functions turn on all available levels; as the operator iteratively zooms out, levels
for smaller features are turned off. When the operator zooms back in, levels are turned back on. A FRAMME global
can be used by the operator to enable or disable the declutter functionality as necessary.
This is a great little MDL tool developed by GORTIS Software Lab (Saint-Petersburg, Russia) as a FRAMME application development and data management tool. The FST Browser Utility is used for browsing and modifying the FRAMME Feature State Table contents for the purposes of function debugging and direct FRAMME data correction.
This MDL tool was developed by GORTIS Software Lab (Saint-Petersburg, Russia) as a FRAMME application development and data management tool. The Interactive SQL Utility is used to enter, edit, and execute SQL queries within a FRAMME environment utilizing the FRAMME SQL Engine and ODBC technology.
One of the neat features of this utility is that it utilizes the Windows clipboard, allowing transfer of data between the Interactive SQL Utility and other Windows applications for further processing. The clipboard is also used by the FRAMME FST Browser utility; allowing the user to read features returned by the ISQL query into the FST Browser for further analysis and modification.
PFE is a multi-file text editor, oriented towards programming but usable for general text handling. PFE is the editor of choice among FRAMME ODL programmers because it handles large files, has many configurable options, and is extendable. FRAMME programmers typically extend PFE to compile ODL and report errors directly into the editor, open familiar Windows applications, and execute 3rd party extensions such as the ODL Variables Declared/Not Referenced Utility.
Development and distribution of Programmer's File Editor has come to an end, and the PFE Web Site is now closed. But have no fear, you can always get the final release of PFE, version 1.01, which is Windows 2000 compliant, right here in the Crow's Nest.
Here are a few tips on configuring PFE, as written by James Franklin.
This utility was developed by Luis Sanchez to detect variables declared in ODL functions but never referenced in the source code. This utility is particularly handy if you've ever seen the ODL error:
%ODL-E-SEMANTIC cfp30501, line 3389: Object code too large: reduce structure and/or array sizes.
The included readme discusses how to execute the utility from within the PFE editor. The output is a list of all the variables declared (and thus taking up valuable space in the object code), but not referenced (never used in the program, so the space is wasted).
Have you ever opened up a FRAMME rulebase text file (like an FDL or ODL) and seen something like this?
This is typical in rulebases that were originally developed on CLIX and migrated to Windows NT. UNIX and MS-DOS systems use different methods to identify end-of-line information in text files. UNIX, including Intergraph CLIX, identifies end-of-line with the linefeed (LF) character. MS-DOS, including Windows 9x/NT/2000, use a carriage return/linefeed pair (CR/LF).
FRAMME and PFE do not have any problems compiling text files regardless of the platform/format combination, but some other useful utilities like WinDiff do. The zip file below contains a utility, developed by Clem Dye and distributed as freeware, that can be used to convert text files in UNIX format to MS-DOS format and visa-versa.
This is a great little MDL application that can really simplify importing 3rd party landbase DGN files into a FRAMME graphic landbase or backdrop class for reference in facility models.
Consider, for example, a FRAMME rulebase that utilizes a landbase such as the Geographic Data Technology Dynamap/2000 or Navigation Technologies NAVTECH Database. These databases can easiliy be converted from their native format to MicroStation design files. They typically are converted a subset of features at a time, into design files for a given county, state, or region.
In order to make them display properly in your rulebase, the files need to be reconfigured such that the contents of each file conform to your index shape placements (often a grid or unique service area configuration).
The Index Shape DGN File Cutter Utility utilizes your rulebase index.dgn file to cut input MicroStation Design files into the appropriate design files for display in your FRAMME rulebase. Review the current Cutter Utility ReadMe file and email us for purchase information for the Index Shape DGN File Cutter Utility.
The Tool for ORACLE Application Development (TOAD) provides a graphical user interface to allow developers and database administrators to quickly view and manage their ORACLE databases. Originally freeware, TOAD has been purchased by Quest Software and is now a commercially supported product.
While performing maintenance on FRAMME rulebases, I often find myself needing to find all the rulebase differences between a new delivery of the rulebase and an older version. Maybe I'm upgrading the FRMKTFLIB at a production site (there are 53 ODL TR fixes from FRKMTFLIB 03.07.00.15 to FRKMTFLIB 04.00.05.04). Maybe I'm working with conversion vendor incorporating fixes from the customer into my custom conversion rulebase. Follow the link below to a list of freeware and shareware utilities designed specifically to compare directories of files and present differences in a visual format.
I'm currently using a combination of TreeComp and WinDiff. TreeComp is freeware and WinDiff is delivered with Visual Studio. WinDiff provides the basic differences engine, but its lacking in user interface. TreeComp sits on top of WinDiff. It has a much better interface for selection of directories to compare, even allowing comparisons over an FTP site (nice for maintaining your website).
Almost all FRAMME applications find a need to access ORACLE data at some time, whether it be FSA tables, rulebase tables, or custom interfaces to other databases in the corporate solution. So how do you create a database connection without hardcoding ORACLE user names and what do you have to do when passwords change?
We recommend storing connection information in the Windows Registry. The registry provides security because end users typically do not have knowledge of or access to the registry. It allows update of dynamic information without redelivering your rulebase. Most IT departments already utilize remote system administration, so maintaining local registry information when changes are made to ORACLE user names and passwords may already be common place in your IT solution.
Have you ever started a FRAMME session and then been horrified by the message that your initial function was not found. Then you poke buttons and find that none of your functions are available. Finally you laugh as you realize that you have two sessions of FRAMME running at the same time (shame on you!). Have your users ever called you up over and over again with the same problem?
Insert this code at the beginning of your Visual Basic main procedure so your application checks for previous instances and exits gracefully if it detects another FRAMME instance running.
' Only one instance of FRAMME can be running at a time.
It takes so long to initiate a FRAMME session, I like to prompt the users to verify their intent to exit before I process an exit request. The easiest way to do this, is to add the following event to the form in your Visual Basic application that contains the FRAMME App Merger Control.
Private Sub MDIForm_QueryUnload(Cancel As Integer, UnloadMode As Integer)
Get fancy and add a third button to File Design on Exit!
ActiveX is the set of technologies that allow separately compiled components to communicate with one another. Communication techniques vary depending on the nature of the components and the environments in which they are created and referenced. ActiveFRAMME presents some unique problems in its communication with MicroStation. It actually acts as two different applications communicating through the Win32 message system. As such, proper utilization of ActiveX DLLs and executables is required to achieve the expected results. Follow this link for a basic review of ActiveX, as written by InStep Technologies, Inc.
After you get the basics of programming in ActiveFRAMME, you ultimately will want to interface with the Windows API (Application Programming Interface). ActiveFRAMME interfaces often call functions within the Windows API to display windows and graphics, manage memory, and perform other tasks.
Microsoft applications such as Visual Basic 6.0 deliver an API Viewer tool that can be used to review the functions in the API. This documentation is ever changing and not very well documented by Microsoft. There are a number of websites and application utilities dedicated to documenting the Windows API and providing tutorials, detailed descriptions of the functions and arguments, example source code, and interesting articles. A nice collection of tutorials, tips and tricks, and articles can be found at VB-World.
Another nice website dedicated to describing the functions comprising the Windows API is Windows API Guide. The reference sections provides a more detailed review of the Windows API functions than can be found in the API Viewer tool provided with Microsoft applications. Detailed descriptions of function arguments and example source assist in integrating the function with your application.
A number of API function browsing utilities have been circulated to assist programmers identify the correct function to use in given situations. The API-Guide, one such utility, is shown below.
The API-Guide, developed and maintained by Kris & Pieter Philippaerts, provides documentation on over 600 Windows API calls. The Group Tree organization makes it easy to search categories of functions to find the exact one required. Programming examples make it simple to cut source and paste directly into your application.
Implementating GIS is often justified by the ability to feed data to other applications in the workplace. Many applications utilize MicroSoft Visual Basic and ADO to build database connections to databases across the corporate infrastructure to access and write data to and from the GIS. Follow this link for a basic review of ADO objects. Source code examples show how to set up ADO connections and perform database operations from within Visual Basic.
This handy ODL utility, developed by James Franklin, dumps the contents of the transaction log to the file tlog.txt in the workset directory. This can be useful in analyzing a workset's contents and reviewing modification histories.
AccuDraw is a set of MicroStation commands that aid in precision input. It can be invoked at the command line in a FRAMME session or incorporated into placement functions. AccuDraw has tons of options and eventually you probably would want to key in:
and review all the functionality, but to give you an idea of what it does, try the following. In a FRAMME session, type in the command:
Change the coordinate system to "polar". This sets the display to distance/angle. Move the distance/angle dialog into your Microstation command area and anchor it out of the way of your map area. Next, type in the command:
Now enter a data point in your map area and see the "compass" appear at that point. Notice that as you move the mouse, the distance/angle dialog is dynamically updated. Key in a specific distance and angle in the dialog and notice how it draws a line from your reference point in the keyed in angle from the reference in the amount specified in the distance.
Now run a FRAMME linear component placement and as you enter data points, notice that the compass jumps to your last point entered and the distance/angle dialog resets based on the move. Notice you can use it to draw "freeform" and use the distance/angle for reference or key in a specific distance and or angle and plot an exact coordinate for your next point.
Keep running FRAMME functions, and notice how annoying this thing can be when you give accept/reject points or a point for text (which generally has no relationship to the last point entered. To disable Accudraw, type the command
AccuDraw is a handy tool in some situations, but what you want to do is to go into your placements and $$issue_application_command to start it at the beginning of the appropriate component placement and then turn it off at the end. Better still, get fancy and add a global for AccuDraw enabled/disabled so some users turn it on and others don't have to.
The following example subroutine, written by Cory Schultz, illustrates how AccuDraw can be incorporated into your placement functions.
This function checks whether the input point is within the closed polygon as defined by the points in the multipoint buffer.
The DEFINE statement in ODL gives the programmer a handy way to create Macro definitions that can be referenced in other parts of your source. Often repeated code sequences can be written once, then referenced throughout the program as required.
And what code sequences do ODL programmers repeat more than anything?
For me, that would have to be those variable conversion primitive calls and $$Issue_prompt's I insert all over the place while attempting to debug my programs.
This handy little file contains macros to $$Issue_prompt any variable in your program. A different macro is used for each of the data types available in FRAMME ODL. Save the file to your rulebase\inc directory.
Reference the file from your ODL function by inserting the following line directly below your procedure declaration:
To quickly test the value of a long variable, insert the following code:
To test the value of a float, insert the following code:
When I finish debugging, I like to just comment the calls out. You never know when you might be back in this function reviewing your logic.
In this 16 slide presentation, Cory Schultz takes a detailed look at FRAMME Data Integrity issues. The presentation begins with a review of common sources of data integrity issues and their effects on quality and productivity. We then look at tools and techniques to monitor data quality, detect problems, and correct them. This presentation was first made at the IGUG in Huntsville, Alabama in May, 2000.
As compiled at the FRAMME UFM SIG 1999 Meeting, the QUEST DataGraphics Top 10 List for 1999 is:
We have had success building ActiveFRAMME interfaces with ActiveBar, developed by Data
Dynamics. ActiveBar has detachable pulldown menus, tabbed menus, and everything docks to the ActiveBar
container. ActiveBar is completely Windows 2000 compliant in interface design. Users can customize most of the
menu layout and restore custom configurations. Sites build typical layouts for such user roles as Overhead and
Underground Engineers. User satisfaction is high since personal preferences are also stored and recalled automatically.
Joining the UtiliComms Exchange User Group is a great way to get familiar with the people in the industry using Intergraph FRAMME products to solve their AM/FM/GIS needs. Communicate regularly with your peers at the UtiliComms Exchange Delphi Forum online.
Most of the MicroStation commands do not work in FRAMME. Even worse, some appear to work but then corrupt the
data or the work environment. We do not advise experimenting with MicroStation commands in a production environment.
If you have a specific workflow issue, drop us an email and we'll try to suggest alternatives that may or may not
include utilization of MicroStation commands.
Here are some more FRAMME System Administrator tasks QUEST DataGraphics recommends, organized by how often they should be performed.
When you invoke your FRAMME application, how many applications appear in your Windows Taskbar? If you invoke
using the bin\model.bat file, you get two; one is the window the bat file is running in and the
other is the FRAMME application.
which sets an environment variable that is later referenced to invoke MicroStation. Change it so it uses the start command to invoke the MicroStation application.
Execution of the bat file as delivered by tools causes the bat file to stop and wait for the MicroStation application to terminate, leaving its window visible in the taskbar. When you invoke MicroStation using the start command, the bat file opens MicroStation in its own window and continues execution of the next line in the bat file. The bat file terminates, and the task is removed from the taskbar.