matrix3dzero

Hi,

Can you guys tell me where I can access matrix3dzero and all the other matrix functions in dotNET?

Are these functions detailed in vba help still the best way to manipulate matrices?

Thanks

Parents
  • Sorry to trouble you with what is probably a dumb question, but how is it implemented?

    If I have:

    BCOM.Matrix3d rotation = BCOM.Application.Matrix3dZero();
    app.CreateTextElement1(null, "hello", ref originPt, ref rotation);

    the error is:

    An object reference is required for the non-static field, method, or property. 'Bentley.Interop.MicroStationDGN.Application.Matrix3dZero()'

    I'm sure this is fundamental C# but I can't find a solution.  Matrix3dZero() returns a zero value of type Matrix3D, so how do I assign that to rotation?

    Thanks

  • An object reference is required for the non-static field, method, or property. 'Bentley.Interop.MicroStationDGN.Application.Matrix3dZero()' 

    You must have an instance of Application object since Matrix3dZero() is a non-static method... So you can't invoke it that way...

    BCOM.Matrix3d rotation = app.Matrix3dZero(); // app == instance of Application class

    but if you need just zero matrix, it's faster to use just its constructor.

     BCOM.Matrix3d rotation = new BCOM.Matrix3d();

Reply Children
No Data