|
DigiPara Liftdesigner LDX API
|
API method: ILDXShaft5.PIT
2 code examples follow.
' from Samples/Src/LDXAPIExamples/Example_GroupsConfiguration.vb
<APIHelpAttribute(APIHelpModes.FireCalcModel Or APIHelpModes.LoadLD3File, {APIHelpModes.InputParaLDXDoc}, "", "LDXShaft~PIT", "Change pit height")>
Public Shared Sub ChangePitHeight(ByRef ldxDocument As DigiPara.LDX.LDXDocument)
If ldxDocument.Shafts Is Nothing Or ldxDocument.Shafts.Count = 0 Then
MsgBox("Shafts not found. Please reload .ld3 file.")
Return
End If
' Change the pit height of first shaft
For Each ldxShaft As DigiPara.LDX.LDXShaft In ldxDocument.Shafts
If ldxShaft.Comp.IX <> ldxDocument.Shafts(0).Comp.IX Then
ldxShaft.SHAFT_MODE = ldxShaft.SHAFT_MODE Or DigiPara.LDX.ShaftModes.smManualPit
End If
Next
ldxDocument.Shafts(0).PIT = 2500
End Sub
' from Samples/Src/LDXAPIExamples/Example_LDXShaft.vb
<APIHelpAttribute(APIHelpModes.FireCalcModel Or APIHelpModes.LoadLD3File, {APIHelpModes.InputParaLDXDoc}, "Shaft0.", "LDXShaft~PIT", "[0247] Change shaft height")>
Public Shared Sub ChangeShaftHeight(ldxDocument As DigiPara.LDX.LDXDocument)
If ldxDocument.GetLDXObject("Shaft0.") Is Nothing Then
MsgBox("Shafts not found!")
Exit Sub
End If
' Shaft height
ldxDocument.Shafts(0).PIT = 8000
ldxDocument.Shafts(0).Head = 8000
ldxDocument.Shafts(0).Object.GetDim("HEAD").Calculate()
End Sub