Quantcast
Channel: MicroStation Programming Forum - Recent Threads
Viewing all articles
Browse latest Browse all 7260

RE: Develop C# code(Visual Studio 2013) for Microstation

$
0
0

.NET InterOp

[quote user="saravana kumar"]C# example for microstation[/quote]

Maury and Jan recommend that you study the VBA API.  The reason they provide that advice is that, for MicroStation V8i, any C# code you write will be calling the VBA COM server via a .NET InterOp.  Therefore, for MicroStation V8i, to write C# code you must understand MicroStation VBA.

Efficiency and Performance

You write that you want to migrate existing MDL (C) code to C#.  Jan asks the question: Why? I ask the same question.  If you have a working MDL application, what advantage will you gain by rewriting it in C#?

One thing you'll definitely lose is performance.  MDL code is reasonably fast; C# code will be comparatively slow because it's calling VBA through an InterOp.  VBA is not a high-performance language (it does a lot of marshalling), and consequently neither will your C# application be high-performance.

Of course, if your app. is not CPU intensive then a small loss of performance is not an issue.  Perhaps there are benefits of moving to C# that you have not mentioned?


Viewing all articles
Browse latest Browse all 7260

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>