cPointObjGetDiaphragm Method |
Namespace: ETABS2016
int GetDiaphragm( string Name, ref eDiaphragmOption DiaphragmOption, ref string DiaphragmName )
If this item is Disconnect then the point object is disconnected from any diaphragm
If this item is FromShellObject then the point object inherits the diaphragm assignment of its bounding area object.
If this item is DefinedDiaphragm then the point object is assigned to the existing diaphragm specified by DiaphragmName
Public Sub Example() Dim SapModel As cSapModel Dim EtabsObject As cOAPI Dim ret As Integer = -1 Dim DiaphragmOption As eDiaphragmOption Dim DiaphragmName As String 'create ETABS object EtabsObject = CreateObject("CSI.ETABS.API.ETABSObject") 'start ETABS application ret = EtabsObject.ApplicationStart() 'create SapModel object SapModel = EtabsObject.SapModel 'initialize model ret = SapModel.InitializeNewModel() 'create steel deck template model ret = SapModel.File.NewSteelDeck(4, 12, 12, 4, 4, 24, 24) 'define a new diaphragm ret = SapModel.Diaphragm.SetDiaphragm("MyDiaph1A", True) 'assign diaphragm to point ret = SapModel.PointObj.SetDiaphragm("1", eDiaphragmOption.DefinedDiaphragm, "MyDiaph1A") 'get point diaphragm assignment ret = SapModel.PointObj.GetDiaphragm("1", DiaphragmOption, DiaphragmName) 'close ETABS EtabsObject.ApplicationExit(False) 'clean up variables SapModel = Nothing EtabsObject = Nothing End Sub