Browse By Tags

  • [MSCE U14 C++, C#] DgnEC Instance and Relationship Change Events

    Introduction With Microstation CE U14, we are introducing a way to listen to DgnEC instance and relationship change events at both Native DgnPlatform and Managed DgnPlatformNet layers w.r.t. the following interfaces: Bentley::DgnPlatform:: IDgnEC ChangeListener…
  • [CONNECT C++] ItemTypeLibraryMgr

    I mentioned ItemTypeLibraryMgr in a post on the Forum. It's a helper class to wrap common usage of the MicroStationAPI with Item Type libraries. Use at your own risk. Support is not included. You need these headers... #include <Mstn/MdlApi/MdlApi…
  • [CONNECT] Create Item Type Property Expression Programmatically

    MicroStation Update 12 introduced Item Type Property Expressions . What a great feature! I could already use Expressions in my apps. Is there an API for Expressions ? in .NET in C++
  • [CONNECT C++] How do I prevent an Item Type property from being edited in the Element Property dialog?

    My app. attaches an Item Type instance to an element. Subsequently, a user may inspect the element using the Element Properties tool... Some Item Type properties are calculated fields (circled in red above). They derive from element properties. However…
  • [CONNECT C++] ReportDefinitionNode::FindByPath

    ReportDefinitionNode::FindByPath attempts to find a report definition node given a text path: Locate a report definition by its full path (including category name). I find that it fails when the category name includes a space. For example, ReportDefinitionNode…
  • [CONNECT C++] Item Type Report -- DgnECHostRelationshipSpecification

    My report successfully harvests information about my Item Type instance properties. Now I want to add related DGN element properties. My Item Type information is specified using DgnECHostSpecification.SetPrimaryClasses . Now I want to use DgnECHostSpecification…
  • [CONNECT C++] Item Types -- Report Definition fails

    My code for AreaAnnotator creates an Item Type definition in the active DGN file if one doesn't already exist. That works fine, and I can add Item data to shape elements. The code also attempts to define a Report , and I am failing miserably. Here's…
  • [CONNECT C++] Item Types -- Report Sort Order and Priority

    Item Type Reports seem to have two qualifiers for sorting: order and priority. When we design a Report interactively we can set the sort order to be ascending or descending... Note that the dialog does not refer to priority. A SortingGroupNode…
  • [CONNECT C++] Item Types - Report Filter Syntax

    SDK example ReportsExample shows how to define an Item Type Report programmatically. There is a commented line that illustrates a filter, to restrict the rows generated in the Report ... reportNode->SetRowFilter (L" this.DgnCustomItemTypes_VendorCatalogItem…
  • [CONNECT C++] Delete Item Type Report Node

    My Item Type defines a ReportCategoryNode that contains ReportDefinitionNode s. While I can see how to add a new report node or find an existing node, I don't see how to delete an existing report node. Any suggestions, or have I missed something?
  • [CONNECT C++] Item Types Pick List API

    MicroStation CONNECT Update 7 documentation has some hints that Picklists are to be introduced to Item Types . That is, the ability of an Item Types schema designer to add a list of possible values that an Item instance can store. Can we expect to see…
  • [CONNECT C++] CommandClass when creating an Item Type

    My app., which includes a CommandTable , creates and deletes Item Type definitions (e.g. using ItemTypeLibrary::Create() ). Which MicroStation CommandClass (from Mstn/MdlApi/cmdclass.r.h ) should I assign to a command that defines an Item Type ?
  • [CONNECT C++] What is the WIP in GetPrivateWipInstance?

    Several methods documented in the MicroStationAPI include 'WIP', as in GetPrivateWipInstance() and GetSharedWipInstance() . What is 'WIP'?
  • [CONNECT C++] Named Group element as Item instance Host

    Can I attach an Item Type instance to a NamedGroup element? Or, to put the question another way, is there any reason why it would be a bad idea to use a Named Group element as an Item instance host?
  • [CONNECT C++] Item Types Report Integration

    I've persuaded AreaAnnotator ™ to create searches and aggregate reports... Behind that dialog are some EC queries that gather information from DGN elements that have Item instance data. Independently of that dialog we can create an Item Type report…
  • [CONNECT C++] Construct ECQuery to get Item Types

    If I build an ECQuery like this, to search for, say, DGN shape elements... ECQueryPtr query = ECQuery::CreateQuery (L"BaseElementSchema", L"MstnClosedBoundary", true); Then use it with DgnECManager.FindInstances (... , *query, ...) I get the result…
  • [CONNECT C++] Item Type custom data

    An Item Type property can take several data types, including custom ... Data types for CustomProperty::Type: Boolean = 0, DateTime = 1, Double = 2, Integer = 3, Point = 4, String = 5, Custom = 6 Can the custom data type be used to store either an…
  • [CONNECT C++] Report Linear Elements

    When I write code using the MicroStationAPI I can analyse any linear element using the ICurveVector API. If I want to measure the length of, say, a line-string or a complex string I can obtain it using CurveVector.Length . I don't need to know what type…
  • [CONNECT C++] Find Elements having Item Type

    I've attached Item Type properties to a number of DGN elements. Now I'd like to find each element having an Item Type attachment. One way (the old way) might be to scan a DGN model and examine each element to see if those attachments are present. Can…
  • [CONNECT C++] EC Schema Property Access

    Methods such as DgnECInstance::GetValueAsString() return an ECN::ECObjectsStatus . There are numerous possible error codes. ECOBJECTS_STATUS_PropertyNotFound Is clear enough, and was useful when I mis-spelled a property name 8-( ECOBJECTS_STATUS_InvalidPropertyAccessString…
  • [CONNECT C++] Copy Item Type Library to a DGN file

    I want to copy an Item Type Library ( ItemTypeLibrary class) from a DgnLib into the active DGN file. Having found the Item Type Library in a DgnLib, I think I want to use ItemTypeLibrary.CloneForFile (activeDgnFile, forReplacement) . What does the second…
  • [CONNECT C++] Item details

    This code extracts Item data as a string... EditElementHandle eeh (...); CustomItemHost itemHost = CustomItemHost (eeh, false); DgnECInstancePtr itemTypes = itemHost.GetCustomItem (libName, itemTypesName); if (itemTypes.IsValid ()) { itemTypes->GetValueAsString…
  • [CONNECT C++] ReportsExample:CreateReport

    The delivered SDK example \annotation\ReportsExample creates a report that isn't quite right (see attachment). ReportsExample.dgn The report has the right no. of columns, but too many rows. Data in rows are misaligned, making the report difficult…