Bentley Communities
Site
Search
User
Site
Search
User
Welcome
Products
Support
About
More
Cancel
Unable to find what you are looking for?
Click here
Platform : Microstation CE 16 (C#), Component : DgnECManager
Varsha Reddy
The below statement causes the issue "object reference not set to an instance of an object" DgnECManager manager = DgnECManager.Manager; Is there any specific thing that is required, along with this? I went through the examples in the SDK, to find…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
DgnECManager::ObtainInstanceEnabler() returns null
Stephan L.
Hello again, does anyone have a clue, why this method could return null? DgnECInstanceEnablerP enabler = DgnECManager::GetManager().ObtainInstanceEnabler(*ecClass, *dgnFileP); checked the ecSchema -> correctly imported, not null checked ecClass…
Answered
over 3 years ago
MicroStation Programming
MicroStation Programming Forum
RE: DgnECManager.Manager.OnInstanceUpdated
Jan Šlegr
Aced2X said: I will use that in the future. It should be possible to edit existing post as well. Aced2X said: I am trying to add 2 new members to the schema. It would be possible, even when it's potentially risky operation. Aced2X said: I want…
over 1 year ago
MicroStation Programming
MicroStation Programming Forum
RE: [C# MSCE 23.00] PropertyHander throwing exception when accessing value
Robert Hook
Hi Mike Robertson , Unless COM Interop is required, below is a (pure) C# code snip YongAn posted to dump an Element's EC Properties that may help; public static void GetProperties(string unparsed) { ulong id; try { id = ulong.Parse(unparsed);…
1 month ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT Update 16 C++] Has Element Property X?
Mangesh.Shelar
You can try to get all instances available on a specific element. And then check if the individual instance has a specific property: // ECQueryProcessFlags flags = intrinsic or extrinsic ECInstanceList GetElementProperties(ElementHandleCR element…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [MicroStation, C#, Managed DLL] Unable to remove referenced schemas
Jan Šlegr
Hi Rodrigo, thanks for your explanation, it helps to understand your question context. Rodrigo Zanini said: When looking at the SDK API (MicroStationAPI.chm) it indicates that ECSchema has a member RemoveReferencedSchema, but I am unable to call it…
7 days ago
MicroStation Programming
MicroStation Programming Forum
[CONNECT C#.NET] ECQuery WhereClause for ECProperties in nested ECClasses help
Aced2X
Even though I am in a 2D drawing, we are using ProStructures v10.7.2.33 (in MicroStation mode) as our base platform with Connect SDK v10.16.02.022 on Windows 11 Enterprise I have an ECSchema that contains an ECClass which contains ECProperties and other…
5 months ago
MicroStation Programming
MicroStation Programming Forum
[.net c#] [ORD 10.10] FindElementById Return null
Ivan Petrov
Hello everyone, I've encountered an issue while working with a .NET C# in the context of ORD 10.11 (I`ve tested under ord 10.11-10.13 - not work.). When I try to use the FindElementById method to locate a specific element within a DgnModel, the method…
30 days ago
MicroStation Programming
MicroStation Programming Forum
[.net c# MicroStation Update 17] get NamedBoundarySavedViewRelationship from NamedView
John Drsek
from a saved view (Named View) i want to get the relationship to the named boundary. form the screen shot i have the saved view named SavedView1 show in the properties dialog. in that properties dialog you can see that the NamedBoundary1 is highlighted…
3 months ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT .net c#] How to copy ECInstance from cell to all its subelements
John Drsek
Thanks Jan, this is all very helpful. i was able to get a new instance added to the sub elements. but its only for the current session of microstation. once i close and reopen the sub elements no longer have the item attached. also im struggling with…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
RE: How to retrieve imported shapefile attribute values that are shown as Item Type properties but no item type library is created by the import?
Jan Šlegr
HI Martin, Martin Tyberg said: It's not clear from the API docs how to load a schema It is true EC Framework documentation is not available as one comprehensive document, but fragmented into chm files, blogs and presentations. Generally I recommend…
over 1 year ago
MicroStation Programming
MicroStation Programming Forum
[MSCE C# C++]Read TypeAdapter applied ECPropertyValue
Snehal Deshpande
This example demonstrates how to read TypeAdapter applied ECPropertyValue. SDK sample path : Managed : examples\DgnEC\ECValueWithTypeAdapter\ManagedExample Helper helper = new Helper(); LineElement lineElement = helper.CreateLineElement(0, 0, 0, 100…
over 1 year ago
MicroStation Programming
MicroStation Programming Blog
RE: [C#] [Microstation updated 17] - Get element last modified date and user.
Jan Šlegr
Hi Ivan, Ivan Petrov said: Does the MicroStation API offer a method to retrieve the last modified date and the username for each element? at first it should be checked, whether MicroStation itself, provides such information. When it is not available…
10 months ago
MicroStation Programming
MicroStation Programming Forum
[CONNECT C#] Grid created by Grid Manager
Tilman Reinhardt
Hi, I am trying to access the grid properties (grid lines, coordinates, orientation, etc.) of a OpenBuildings Designer model from a c# addin. I can see from the XML export that the used EC schema should be StructuralModelingComponents.06.00 . When I ask…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
Platform : Microstation CE 16 (C#) - Some properties are not accessible from the element
Varsha Reddy
I see the properties for the cell element like gasket, but unable to retrieve some through the code mentioned below. This code gives me properties of category like "Raw Data", "Extended" etc., but does not gives the category and its properties highlighted…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [Mstn CE U16 C#] Attaching ECW raster georeferenced
Peter Norvin
I have found a solution, it is possible to change GCS using DgnECManager, as Jan sugested. My code now looks like this, and seems to work, regardless of which GCS is defined in the design file: BDPN.DgnFile DgnFile = BM.Session.Instance.GetActiveDgnFile…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT .NET] Use IElementPropertyEnabler to obtain DGN Element properties
Paul Connelly
IElementPropertyEnabler won't be useful to you. If you want DGN element properties, whether in native or .NET, DgnECManager is usually the place to look.
over 4 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT C++] Using a WhereCriterion to filter out schemas
Yongan.Fu
Hi Bruce, If you only want to find a specific [ ECShema: ECClass] on an element, I think it doesn't need to use WhereCriterion. Below is an example which can get [BaseElementSchema:MstnVolume] on an element. void getVolumeByEC(WCharCP unparsed) …
over 4 years ago
MicroStation Programming
MicroStation Programming Forum
[MStn CE U17.2 C#] EC data difference between ORLD and MStn
Jan Šlegr
Hi all, this my question relates to "formulated differently, but about the same topic", posted to civil programming forum . I am aware I am discussing how to hack DGN content, and furthermore created in OpenRail Designer, not in plain MicroStation…
5 months ago
MicroStation Programming
MicroStation Programming Forum
[MSCE U17 C#] Show Properties of DgnEC Instance in Property Pane.
Amol Shinde
Introduction This blog provides some code snippets that demonstrate " How to show Properties of DgnEC Instance in Property Pane " SDK Sample MstnExamples\DgnEC\DgnECManagedPropertyPaneExample Steps: Locate and load the schema from…
over 4 years ago
MicroStation Programming
MicroStation Programming Blog
RE: Setting global linestyle scale on model reference in CONNECT
Lubo B
Hello, sorry for late response, but after some time has passed and I didn´t find a way with native MDL, I´ve decided to give EC API a try. However, it feels like I´m missing something. FindInstancesScopePtr ptr = FindInstancesScope::CreateScope(*modelRef…
over 2 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT c++] get EC instance of itemtype on element?
Jon Summers
John Drsek said: I need to get the ec instance of an item type instance that is attached to an element This article about EC Queries may help. It distils tips that Paul Connelly and others have given over the years. You need to create a scope and a…
over 4 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [Connect C++] How to read custom properties (no standard properties) on elements
Jon Summers
danny zhu said: do you have suggestions? Here's some code to get EC Schemas ... #include <EcHeaders.h> USING_NAMESPACE_BENTLEY_DGNPLATFORM; USING_NAMESPACE_BENTLEY_ECOBJECT; WCharCP SchemaFactory::BaseElementSchemaName = L"BaseElementSchema"; WCharCP…
over 6 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT C#] how to change a dgn file properties (title, comments)
John Drsek
got this from Artur Goldsweer from Bentley Support. He said to get it from the EC data. here is some code sample he gave me. using BD = Bentley.DgnPlatformNET; ---------------------------------------- BD.DgnEC.DgnECManager dgnECManager = BD…
over 4 years ago
MicroStation Programming
MicroStation Programming Forum
RE: [CONNECT C++] TextField::CreateForModel
Jon Summers
This works … DgnModelP model { ISessionMgr::GetActiveDgnModelP () }; FindInstancesScopeOption option (DgnECHostType::Model); FindInstancesScopePtr scope { FindInstancesScope::CreateScope (*model, option) }; ECQueryPtr query { ECQuery::CreateQuery (L…
over 5 years ago
MicroStation Programming
MicroStation Programming Forum
>