SapObject.SapModel.FrameObj.GetEndLengthOffset
Function GetEndLengthOffset(ByVal Name As String, ByRef Auto As Boolean, ByRef Length1 As Double, ByRef Length2 As Double, ByRef rz As Double) As Long
Name
The name of an existing frame object.
Auto
If this item is True, the end length offsets are automatically determined by the program from object connectivity.
Length1
The offset length along the 1-axis of the frame object at the I-End of the frame object. [L]
Length2
The offset along the 1-axis of the frame object at the J-End of the frame object. [L]
rz
The rigid zone factor. This is the fraction of the end offset length assumed to be rigid for bending and shear deformations.
This function retrieves the frame object end offsets along the 1-axis of the object.
The function returns zero if the offsets are successfully retrieved, otherwise it returns a nonzero value.
Sub GetFrameEndOffsets()
'dimension variables
Dim SapObject As Sap2000.SapObject
Dim SapModel As cSapModel
Dim ret As Long
Dim Auto As Boolean
Dim Length1 As Double
Dim Length2 As Double
Dim rz As Double
'create Sap2000 object
Set SapObject = New SAP2000.SapObject
'start Sap2000 application
SapObject.ApplicationStart
'create SapModel object
Set SapModel = SapObject.SapModel
'initialize model
ret = SapModel.InitializeNewModel
'create model from template
ret = SapModel.File.New2DFrame(PortalFrame,
3, 124, 3, 200)
'get offsets
ret = SapModel.FrameObj.GetEndLengthOffset("15",
Auto, Length1, Length2, rz)
'close Sap2000
SapObject.ApplicationExit False
Set SapModel = Nothing
Set SapObject = Nothing
End Sub
Initial release in version 11.00.