Dear all,
I am a newbie in MicrostationAPI (using C#). I am following Learning MicroStation Addins Step by Step to create an Addin. It seems MicroStationAPI has changed very much since the post was created. Therefore I got stuck in KeyinTree problem when trying to use commands.xml to structure commands.
In the post, they use parameter KeyinTree in namespace Bentley.Microstation. In the current MicroStationAPI, however, this namespace is replaced with Bentley.MstnPlatformNet (if I understand right, because I could not find Bentley.Microstation), therefore AddInAttribute definition no longer includes KeyinTree.
Could anyone tell me how I can handle this problem?
Thanks in advance.
Hi,
in addition to Valerio's post: You should be aware of changes between V8i and CONNECT Edition. The blog you mentioned was written for V8i, but the current CONNECT Edition use different API, so the blog cannot be used 1:1.
An important change is how key-in xml definition is implemented, I recommend to search MicroStation Programming forum for discussions how to configure Visual Studio project properly, because it has to be done manually.
With regards,
Jan
Bentley Accredited Developer: iTwin Platform - AssociateLabyrinth Technology | dev.notes() | cad.point
Just follow Learning MicroStation Addins Step by Step , additionally, modify the .csproj file manually, and make sure the command.xml has a LogicalName field as below.
<ItemGroup> <EmbeddedResource Include="AddinInitialize\Commands.xml"> <SubType>Designer</SubType> <LogicalName>CommandTable.xml</LogicalName> </EmbeddedResource> </ItemGroup>
That is the only change I made on the "... step by step", and it worked immediately.
Hope this can be of some help.
Regards,
Frank