SapObject.SapModel.Results.BucklingFactor
Function BucklingFactor(ByRef NumberResults As Long, ByRef ACase() As String, ByRef StepType() As String, ByRef stepnum() As Double, ByRef Factor() As Double) As Long
NumberResults
The total number of results returned by the program.
ACase
This is an array that includes the name of the analysis case or response combination associated with each result.
StepType
This is an array that includes the step type for each result. For buckling factors, the step type is always Mode.
StepNum
This is an array that includes the step number for each result. For buckling factors, the step number is always the buckling mode number.
Factor
This is an array that includes the buckling factors.
This function reports buckling factors obtained from buckling analysis cases.
The function returns zero if the factors are successfully recovered, otherwise it returns a nonzero value.
See Analysis Results Remarks for more information.
Sub GetBucklingFactors()
'dimension variables
Dim SapObject As Sap2000.SapObject
Dim SapModel As cSapModel
Dim ret As Long
Dim NumberResults As Long
Dim ACase() As String
Dim StepType() As String
Dim StepNum() As Double
Dim Factor() 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
'open model
ret = SapModel.File.OpenFile("C:\SapAPI\Example
1-019a.sdb")
'run analysis
ret = SapModel.Analyze.RunAnalysis
'clear all case and combo output selections
ret = SapModel.Results.Setup.DeselectAllCasesAndCombosForOutput
'set case and combo output selections
ret = SapModel.Results.Setup.SetCaseSelectedForOutput("BUCK1")
'get buckling factors
ret = SapModel.Results.BucklingFactor(NumberResults,
ACase, StepType, StepNum, Factor)
'close Sap2000
SapObject.ApplicationExit False
Set SapModel = Nothing
Set SapObject = Nothing
End Sub
Initial release in version 11.00.