[ORD 10.09 C#] example AlignmentEdit Null Exception

I'm trying to develop my own Alignment Import MDL addin.

I get a null exception, I've tried running the OpenRoadsDesignerCONNECTSDK example for ComplexAlignmentCreator

and get the same null exception in this line, AlignmentEdit al = AlignmentEdit.CreateByLinearElement(con, complexAlign, true);

Is there two points that this will work for?

Can anyone confirm if they also get the same behavior? ORD CE 2021 Release 1



  • Hi Jon,

    I just ran through this example on ORD 2021 R1 and I didn’t have any problems, errors or exceptions.

    Can you tell me more about what else was going on when you tested the ComplexAlignmentCreator example?

    Is your file metric or imperial units?

    Does it happen in existing files and in new files?

    Is there currently geometry data in the dgn?

    Are you snapping to anything when you select your two data points?

    Have you modified the example?

    Did you build it on the same machine and ORD version that you are testing the example?

    Have you run any other examples successfully?

    I know that's a lot of questions. However, since its working for me, I'm just trying to figure out what is different.



  • Thanks for confirming.  I didn't modify the example.  I'm installing ORD on a different computer to test and will post back when I test there.

    I did build against the installed version dlls (I updated the references)  in a metric file.

  • Ok, I did install anew on a different computer. 

    I've now identified the issue.  The mdl app I'm building was copying some of the referenced dlls to the mdl app folder.

    This was causing the error, when I suppressed this, I get the keyin command running without problem.

    Thanks for taking the time to reply.



    Answer Verified By: Jon Mirtschin 

Reply Children
No Data