I have the next code: public void Update(IDgnECInstance instance, string propertyName, string value)
{
instance.SetAsString(propertyName, value);
instance.WriteChanges();
} How can I enable users to reverse actions performed in my custom form using…
I am writing an application for MicroStation and ORD under c# I plan to cache specific data to improve the application's startup speed following a session involving a file. In light of this, having access to a file hash would be extremely helpful. Does…
I currently have this code in C# in a console application, the only thing at the moment is wanting to open microstation connect edition, but unfortunately it throws an error or returns null
static void Main(string[] args)
{
try
{
Type type1…
Hi.
I need to change the display style of a element to wireframe.
My goal is that view and element have different display style.
Do anyone know how to do change display style of element in C# API?
Thank you.
hi
I am trying to place an element in C# Addin .Net, but since the default global origin of the seed file is not (0,0,0). I am unable to place the element at the correct coordinates. I tried to change the global origin with this code, but it didn't…
Hello All,
I have written a routine to generate a shape from a series of points and then utilize the shape to define a fence from element.
I would like to process the fence in two separate routines one that will clip normal element type like Lines…
Hello,
I need to convert ellipses with different Primary and Secondary Axis to multiple arcs with the same Primary and Secondary Axis. In Microstation I can do that using Facet tool but I need to achive the same result doing it programatically.
…
Hi,
I am trying to to develop a plugin for MicroStation with .net framework, following this tutorial :
https://communities.bentley.com/products/programming/microstation_programming/w/wiki/52303/introduction-and-prerequisite
I have those installed…
Hello, folks! For once, SDK has a rather extensive example for programming WPF applications. This example is called WPFdemo. Here you can open a dockable toolbar with 'wpfdemo open5'. So far so good.
But now I would like this toolbox to behave like…
Hello All
Using C# I can create item types and attach them to elements, but cannot see how to attach an set of ItemType properties to a dgn model?
I can get to the model as a DgnModel and ModelInfo
I can get to my ItemTypeLibrary and ItemType
…
Hi, ElementPropertiesSetter.SetFillColor does not set the FillColor of e.g. a Shape, as one might think.
What works perfectly with ElementPropertiesSetter.SetColor does not work here.
In DgnPlatformNet.chm there is a note about this: Will not add…
Hello, As you know, a shape stops at 5000 vertices. When this limit is reached, I want my method to automatically create a ComplexShape.
Here is an excerpt from my source code, where this works with <= 5000 for pure Shape elements. With more than 5000…
OS: Windows 10
Application: MicroStation Connect Edition update 13 - v10.13.01.01
Language of the Application: C#
.NET Framework: 4.7.2
Goal: To unload the AddIn when MicroStation Connect closes a file.
Workflows to support:
Workflow 1…
Using the IModelMessage.SendMessage() it seems that messages are restricted to 255 characters to get passed back to the calling application through IPC. All chars after the 255 limit seem to be stripped off and not send back on a proceeding call. Is there…
When starting MicroStation.exe via Process.Start(), how to redirect "MicroStation Text Window" text? Here is how the exe is being started and trying to capture the output stream:
ProcessStartInfo commandInfo = new ProcessStartInfo();
commandInfo.WorkingDirectory…
When a .cit file is opened within MicroStation it says that it is read-only and that it is a Raster Attachment. Is there a way to extract text from it through code? Within MicroStation, it seems that the layers have been flattened and no longer useable…
Hi there,
New to the MicroStation SDK - I am familiar with the AutoCAD ObjectARX lib. I see that RealDWG is included with MicroStation but when I am trying to perform the same code I have in AutoCAD it is not working the same within a C# MDL app in…
Hi,
I am trying to initialize BentleyView application in my C# Class Library using 'Bentley.Interop.MicroStationDGN'. Following is the snippet I am using:
private Application application;
public Class1()
{
ApplicationObjectConnector…
Referencing a previous post about creating dimension elements in C#: https://communities.bentley.com/products/programming/microstation_programming/f/microstation-programming---forum/112608/c-connect-how-to-create-dimension-elements
I've been trying…
I have questions regarding the usage of the formatter for NET API based on http://www.la-solutions.co.uk/content/CONNECT/DgnPlatformNet/Mensuration.htm :
1. In the article, it is mentioned that the formatter is Initialised using active DGN model coordinate…
Hi,
I want to load an existing workspace. It already works with an existing workset.
using BD = Bentley.DgnPlatformNET;
using BM = Bentley.MstnPlatformNET;
// Load Workset
BM.Internal.WorkSpaceManager.ActiveWorkSet.WorkSetInfo.Name = myWorksetName;…
Hello,
I have a question. Is it possible to make a C# DLL usable in a VBA project and if yes, how?
We already tried with the following Link:
https://www.geeksengine.com/article/create-dll.html
But in that example you have to move a file in to…