Bentley Communities
Bentley Communities
  • Site
  • User
  • Site
  • Search
  • User
OpenCities Map
  • Product Communities
  • Geospatial
  • OpenCities Map
  • Cancel
OpenCities Map
OpenCities Map Wiki - Extended Properties (xProps MDL)
    • Sign In
    • -OpenCities Map Wiki
      • -OpenCities Map
        • - End of Support for Bentley Map V8i (SELECTseries) products
        • +Release Information
        • +Installation Information
        • +Getting Started
        • +Administration
        • +General Topics
        • +Geospatial Administrator
        • +Feature Definitions and Inference Rules
        • +Interoperability
        • +Spatial Databases
        • +Spatial Analysis
        • +3D Geospatial
        • +Geographic Coordinate Systems
        • +Troubleshooting
        • -Freeware - Utilities - Applications - Programs
          • - Auto update Editing initial values (Sync1 MDL)
          • - Centroid text to shape (VBA)
          • - Change feature elevation (VBA)
          • - Convert text to XFM and propagate text string to shapes using VBA
          • - Create schema from Shapefiles (Schema Register EXE)
          • - Export text string and Element ID (TextNodeToTextFile VBA)
          • - Extended Properties (xProps MDL)
          • - Label latitude and longitudes (VBA)
          • - Learning Resources
          • - Load properties from text strings (text2xfm VBA)
          • - Planarize 3D Polygon (MDL)
          • - Show XFM Properties on tool tips (MDL)
          • - Symbology Integrator (EXE)
          • - Utilities from Elivagner Barros
          • - XFM attribute query (Feature Query VBA)
          • Setting Level for reference attachment (VBA)
        • +Advanced Map Finishing
      • OpenCities Map Ultimate for Finland CONNECT Edition x64 (SES)
      • OpenCities Map Ultimate for Finland CONNECT Edition - Suomi
      • Bentley Descartes
      • +Other Geospatial Products

     
     Questions about this article, topic, or product? Click here. 

    - Extended Properties (xProps MDL)

    We are very pleased to provide the OpenCities Map user community the attached Bentley MDL application that seamlessly extends feature properties to include MicroStation element information such as:  text strings, cell names, cell scales, XY coordinate positions, and latitude/longitude positions.    

    This MDL is available for both the CONNECT and V8i generation of OpenCities Map products.

    The extended properties are exposed in the Element Information dialog, as well as any dialog you find OpenCities Map XFM properties.  This includes the Data Browser, Interoperability dialog, and several of the Map Manager functions including feature labels, and the search dialog.

    Each zip file at the end of this article contains:

    • xprop.ma and xprop.dll files to be placed in ...\Map\mdlapps\
    • An illustrated PDF documenting its usage
    • A brief video showing usage - you can preview it here:

    Play this video

    Contents

    • Introduction
    • Installation and Configuration
    • Geographic Coordinates
    • Feature Types
    • Usage
    • Analyze XFM Feature
    • Data Browser
    • Map Interoperability
    • Property Based Annotation (PBA)
    • Labeling
    • Searching
    • Thematic Resymbolization
    • Disclaimer
    • Downloads

    Introduction

    The following article discusses the usage and implementation of xprops.ma, a custom OpenCities Map MDL application that seamlessly extends feature properties to include MicroStation element information such as: text strings, cell names, cell scales, XY coordinate positions, and latitude/longitude positions.  

    The extended properties are exposed in the Element Information dialog, as well as any dialog you find OpenCities Map XFM properties. This includes the Data Browser, Interoperability dialog, and several of the Map Manager functions including feature labels, and the search dialog.

    The following graphic illustrates the Element Information dialog without xprops loaded (left) and the same element with xprops loaded (right).

    Installation and Configuration

    The xprops application is an MDL program provided with this article. Extract and place copies of the DLL and MA files in either the ...\Map\mdlapps\ or …\MicroStation\mdlapps\ folder.

    If desired the configuration variable MS_GEOINITCMD can be defined to automatically load the MDL when an OpenCities Map session is started. This can be done in the Bentley Geospatial Administrator by adding a new entry in the Workspace Macros node:

     If you prefer, you can manually start the application using the keyin

    mdl load xprops

    To unload the application, use the keyin

    mdl unload xprops

    This keyin may need to be run twice to fully unload the application from your design session.

    Once loaded, the following keyins are available:

    Keyin Description
    XPROPS VERSION Displays application build time.
    XPROPS ON|OFF Enables or disables extended properties for all feature classes.
    XPROPS OFF=MyFeatureClassName

    Disables extended properties for specific feature class.

    For example, to turn off the extended properties for a feature class called Lights, use the keyin

    XPROPS OFF=Lights

    XPROPS ON=MyFeatureClassName

    Enables extended properties for specific feature class.

    For example, to turn on the extended properties for a feature class called Lights, use the keyin

    XPROPS ON=Lights

    Geographic Coordinates

    A strength of this application is its ability to recognize the attached Geographic Coordinate System (GCS) and provide you with the latitude and longitude coordinates of your features. The geographic extended properties are described as:

    Property Name Description
    _Latitude The latitude of the point or vertex expressed in decimals.
    _LatitudeString The latitude expressed in either decimal degrees or degrees/minutes/seconds.
    _Longitude The longitude of the point or vertex expressed in decimals.
    _LongitudeString The longitude expressed in either decimal degrees or degrees/minutes/seconds.

    For searching based on geographic locations, use the _Latitude and/or _Longitude properties.

    For feature labels and PBA text values, use the string variation which includes the degree symbol.

    To control how the string variation is displayed, adjust the design file angle readout to either DD.DDD or DD MM SS. You can find this by navigating to File > Settings > File > Design File Settings > Angle Readout > Format . Changing the angle format is immediate and reflected when the view is updated or dialog is reopened.

     

    Deleting the coordinate system from the DGN File will remove the latitude and longitude extended properties that are made available for use in OpenCities Map.

    As well, changing the coordinate system from one to another, may require the design file to be closed and reopened in order to display the new geographic coordinates.

    Feature Types

    The extended properties will vary for each of the feature types: polygon, line and point. 

    The following element types are supported by xProps:

    Polygon Features: Shape, Closed B-Spline, Complex Shape, Ellipse

    Linear Features: Arc, B-spline Curve, Complex Chain, Curve, Line String

    Point: Cell, Text

    Polygons will show the XY(Z) coordinates of all vertices, and the geographic coordinates of the first vertex.

     

    (Polygon Collections are not supported)

    The extended properties for Point Cell features includes the cell name, scale, angle in addition to the origin XY(Z) and geographic coordinates.

     

    For Point Text features, the text string is returned as well as the origin coordinates. In the graphic below, there is no coordinate system defined in the file. As a result, the latitude/longitude extended properties are not available for display or use.

     

    For linear features that consist of a single line, you’ll find the XY(Z) and geographic coordinates for the start and end points as well as the line direction expressed in degrees.

    For line strings, the coordinates for all vertices are returned, and the direction is based on the first segment.

    Usage

    Once loaded, xprops seamlessly extends business properties for all OpenCities Map session data and does this without changing the element or XFM feature instances. In addition, since the extended properties are only available when xprops is running, nothing is written to the design file.

    The following examples illustrates just some of the usage of xprops in a typical OpenCities Map project.

    Analyze XFM Feature

    Review a feature's extended properties with the Analyze XFM Feature tool. The properties are easily recognizable by their underscore prefix. Note that the content ordering of the Analyze Result dialog is controlled by default.xslt.

    Data Browser

    When using the Data Browser, the extended properties will appear to the right of the XFM properties and are read-only.  

    Once loaded, you can use any of the Data Browser tools to refine the display of the rows.

    For example:

    • Order the content based on the size, name or angle of the cell.
    • Sort the data by their latitude/longitude values in order to locate or highlight features based on their geographic location.
    • Perform query-finds on specific values, copy values to insert into other applications for further analysis.
    • And even add features to a MicroStation selection set based on their extended properties.

    NOTE: If you do not see the Extended Properties in the Data Browser it could be that the data is from a Query to a Spatial Database, such as ESRI File Geodatabase, SQL Server, or PostGIS.  To see the extended properties in the Data Browser, save the DGN File as a .dgn and the XFM and Extended Properties will be available.

    Map Interoperability

    Create a Where Clause when exporting features to another GIS format such as ESRI Shapefiles.

    Property Based Annotation (PBA)

    Knowing that the extended properties can be used anywhere you would also use XFM properties, incorporate them into your schema for generating Property Based Annotation expressions.  

    Labeling

    The extended properties are available in the Map Manager Labeling dialog as well. In this example, the name of the cell and size is being labeled. Note the use of [XFM.Round([property)].2)] to round up the scale value.

     

    Searching

    Searching on the extended properties is no different than searching on XFM properties.   When searching on longitude or geographic values, use _Latitude or _Longitude.   This eliminates the need to enter a degree symbol when searching on _LatitudeString and _LongitudeString.

    Thematic Resymbolization

    When it comes to resymbolizing your map based on properties, the xprop application provides a number of advantages. For example, you can now resymbolize point cell features based the cell name as well as the geographic location.   The ability to create search criteria with both XFM and extended properties allows an infinite number of Map Manager resymbolizing strategies.

    Disclaimer

    This application is supplied as-is and does not come with Support. Bentley Systems Inc., and the author of this programs assume no liability for damages direct, indirect, or consequential, which may result from the use of this program. Use this application at your own risk.

    Downloads

    A PDF of this article is available for downloading: 


    PDF

    Download: Choose the appropriate xProps zip file based on your version of OpenCities Map

    OpenCities Map CONNECT Edition x64 Bentley Map V8i edition x86
    xprops_x64.zip xprops_x86.zip
    • xprops
    • XFM
    • Analyze Results
    • element information
    • Bentley Map
    • Extended Properties
    • Share
    • History
    • More
    • Cancel
    • Dan Weston Created by Bentley Colleague Dan Weston
    • When: Thu, Apr 27 2017 11:54 AM
    • Dan Weston Last revision by Bentley Colleague Dan Weston
    • When: Wed, Mar 9 2022 1:50 PM
    • Revisions: 36
    • Comments: 0
    Recommended
    Related
    Communities
    • Home
    • Getting Started
    • Community Central
    • Products
    • Support
    • Secure File Upload
    • Feedback
    Support and Services
    • Home
    • Product Support
    • Downloads
    • Subscription Services Portal
    Training and Learning
    • Home
    • About Bentley Institute
    • My Learning History
    • Reference Books
    Social Media
    •    LinkedIn
    •    Facebook
    •    Twitter
    •    YouTube
    •    RSS Feed
    •    Email

    © 2023 Bentley Systems, Incorporated  |  Contact Us  |  Privacy |  Terms of Use  |  Cookies