DigiPara Liftdesigner LDX API
Loading...
Searching...
No Matches
Change car door reference point properties

API method: ILDXCarDoor5.CarDoorMode

Treename: Shaft0.Car.Door1.

 ' from Samples/Src/LDXAPIExamples/Example_LDXCarDoor.vb

    <APIHelpAttribute(APIHelpModes.FireCalcModel Or APIHelpModes.LoadLD3File, {APIHelpModes.InputParaLDXDoc}, "Shaft0.Car.Door1.", "LDXCarDoor~CarDoorMode", "[0191] Change car door reference point properties")>
    Public Shared Sub ChangeCarDoorReferencePointProperties(ldxDocument As DigiPara.LDX.LDXDocument)

        If ldxDocument.GetLDXObject("Shaft0.Car.Door1.") Is Nothing Then
            MsgBox("Car front door not found!")
            Exit Sub
        End If

        Dim ldxCarDoor As DigiPara.LDX.LDXCarDoor = ldxDocument.Shafts(0).Car.GetDoor(DigiPara.LDX.WallType.wtFront)

        With ldxCarDoor
            If MsgBox("Set reference point to center of car? If not it will be set to the left.", MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
                ' Set the reference point to the center of the car
                .CarDoorMode = 0
                ' Set clearence distance
                .CLDist = 333
            Else
                ' Set the reference point to the left of the car
                .CarDoorMode = DigiPara.LDX.CarDoorModes.camConstrainedLeft
                ' Set clearence distance
                ldxDocument.Shafts(0).Car.SetEL(DigiPara.LDX.WallType.wtFront, 222)
            End If
        End With

    End Sub