Solid Edge Assembly Type Library
SetUserDefinedAssemblyPhysicalProperties Method
Specify value to be set for Volume.
Specify value to be set for Area.
Specify value to be set for Mass.
Specify Center of Mass in the form of an array. Representation for Center of Mass is {X, Y, Z}
Specify Center of Volume in the form of an array. Representation for Center of Volume is {X, Y, Z}
Specify Global Moment of Inertia in the form of an array. Representation for Global Moment of Inertia is {xx, xy, xz, yy, yx, zz}
Specify Principal Moments in the form of an array. Representation for Principal moments is {l1, l2, l3}
Specify Principal Axis1 in the form of an array.
Specify Principal Axis2 in the form of an array.
Specify Principal Axis3 in the form of an array.
Specify Radii of Gyration in the form of an array. Representation for Radii of Gyration is {k1, k2, k3}.
Specify value to be set as User-quantity Mass.
Description
Set user defined physical properties to the physical property object of an assembly.
Syntax
Visual Basic
Public Sub SetUserDefinedAssemblyPhysicalProperties( _
   ByRef Volume As Double, _
   ByRef Area As Double, _
   ByRef Mass As Double, _
   ByRef CenterOfMass() As Double, _
   ByRef CenterOfVolume() As Double, _
   ByRef GlobalMoments() As Double, _
   ByRef PrincipalMoments() As Double, _
   ByRef PrincipalAxis1() As Double, _
   ByRef PrincipalAxis2() As Double, _
   ByRef PrincipalAxis3() As Double, _
   ByRef RadiiOfGyration() As Double, _
   ByRef OverrideMass As Double _
) 
Parameters
Volume
Specify value to be set for Volume.
Area
Specify value to be set for Area.
Mass
Specify value to be set for Mass.
CenterOfMass
Specify Center of Mass in the form of an array. Representation for Center of Mass is {X, Y, Z}
CenterOfVolume
Specify Center of Volume in the form of an array. Representation for Center of Volume is {X, Y, Z}
GlobalMoments
Specify Global Moment of Inertia in the form of an array. Representation for Global Moment of Inertia is {xx, xy, xz, yy, yx, zz}
PrincipalMoments
Specify Principal Moments in the form of an array. Representation for Principal moments is {l1, l2, l3}
PrincipalAxis1
Specify Principal Axis1 in the form of an array.
PrincipalAxis2
Specify Principal Axis2 in the form of an array.
PrincipalAxis3
Specify Principal Axis3 in the form of an array.
RadiiOfGyration
Specify Radii of Gyration in the form of an array. Representation for Radii of Gyration is {k1, k2, k3}.
OverrideMass
Specify value to be set as User-quantity Mass.
Example
Imports System.Runtime.InteropServices
Public Class Form1

    Private Sub SetUserDefinedAssemblyPhysicalProperties_Click(sender As Object, e As EventArgs) Handles SetUserDefinedAssemblyPhysicalProperties.Click
        Dim objApplication As SolidEdgeFramework.Application = Nothing
        Dim objAssemblyDocument As SolidEdgeAssembly.AssemblyDocument = Nothing
        Dim oPhysicalProps As SolidEdgeAssembly.PhysicalProperties = Nothing

        Dim dblMass As Double
        Dim dblVolume As Double
        Dim dblArea As Double
        Dim dblCofMass(3) As Double
        Dim dblCofVolume(3) As Double
        Dim dblGlobalMoments(6) As Double
        Dim dblPrincipalAxis1(3) As Double
        Dim dblPrincipalAxis2(3) As Double
        Dim dblPrincipalAxis3(3) As Double
        Dim dblPrincipalMoments(3) As Double
        Dim dblRadiiOfGyration(3) As Double
        Dim dblOverridedMass As Double

        Try

            objApplication = Marshal.GetActiveObject("SolidEdge.Application")

            objAssemblyDocument = objApplication.ActiveDocument

            oPhysicalProps = objAssemblyDocument.PhysicalProperties


            oPhysicalProps.UserDefinedPropertiesStatus = True

            dblMass = 5
            dblVolume = 0.0135
            dblOverridedMass = 15
            dblArea = 57
            dblCofMass = {15, 0.5, 5}
            dblCofVolume = {35, 0.05, 53}
            dblGlobalMoments = {1, 4, 3, 5, 8, 7, 9}
            dblPrincipalAxis1 = {3, 9, 5}
            dblPrincipalAxis2 = {7, 5, 6}
            dblPrincipalAxis3 = {5, 8, 5}
            dblPrincipalMoments = {4, 3, 5}
            dblRadiiOfGyration = {1, 5, 2}


            Call oPhysicalProps.SetUserDefinedAssemblyPhysicalProperties(dblVolume, dblArea, dblMass, dblCofMass, dblCofVolume, dblGlobalMoments, dblPrincipalMoments, dblPrincipalAxis1, dblPrincipalAxis2, dblPrincipalAxis3, dblRadiiOfGyration, dblOverridedMass)

        Catch ex As Exception
            MsgBox(ex.ToString)
            Clipboard.SetText(ex.ToString)
        End Try

    End Sub
End Class
See Also

PhysicalProperties Object  | PhysicalProperties Members