(ORD C# - 2021 Release 1) How to get all Surface Template element?

Hello.

I am trying to get all Surface Template element using C# SDK.

But I don't know how to get Surface Template element.

Is there any way to get all Surface Template element?

Thank you.

Parents
  • Try the code below.

                    Bentley.CifNET.SDK.Edit.ConsensusConnectionEdit sdkCon = Bentley.CifNET.SDK.Edit.ConsensusConnectionEdit.GetActive();
                    if (sdkCon == null)
                        return;
    
                    GeometricModel geomModel = sdkCon.GetActiveGeometricModel();
                    if (geomModel == null)
                        return;
    
                    // This is how you get the surface temapltes
                    foreach (var s in geomModel.CorridorSurfaces)
                        {
                        }
    

    I hope it helps.

    Henrique

Reply
  • Try the code below.

                    Bentley.CifNET.SDK.Edit.ConsensusConnectionEdit sdkCon = Bentley.CifNET.SDK.Edit.ConsensusConnectionEdit.GetActive();
                    if (sdkCon == null)
                        return;
    
                    GeometricModel geomModel = sdkCon.GetActiveGeometricModel();
                    if (geomModel == null)
                        return;
    
                    // This is how you get the surface temapltes
                    foreach (var s in geomModel.CorridorSurfaces)
                        {
                        }
    

    I hope it helps.

    Henrique

Children