PC-DMIS 2021.1 Object Library
CurrentArm Property
See Also  Send Topic Feedback | See Object Hierarchy Chart
PCDLRN ActiveX DLL > PartProgram Object : CurrentArm Property

Glossary Item Box

Description

This read/write property returns or sets the active arm when using PC-DMIS in multiple arm mode.

Syntax

Visual Basic
Public Property CurrentArm As Long

Return Type

Read/write Long value.

Example

Sub Main

' This script queries the system for the

' active arm number, displays the active arm,

' and asks you if it should be changed.

' If you click Yes, then an input box

' appears allowing you to type the

' new active arm number. The script then

' updates the software to use the newly

' specified arm.

  Dim App As Object

  Set App = CreateObject ("PCDLRN.Application")

  Dim Part As Object

  Set Part = App.ActivePartProgram

  Dim intNumArm As Integer

  Dim intResponse As Integer

  intNumArm = Part.CurrentArm

  intResponse = MsgBox("The current active arm is " & intNumArm & ". Do you want to change the active arm?",4+32+0,"Change Active Arm?")

  If intResponse = "6" Then

    intNumArm = InputBox("Type the new active arm number (1 or 2): ")

    Part.CurrentArm = intNumArm

    MsgBox "Your active arm has been changed to " & intNumArm

  Else

    MsgBox "Nothing has changed. Closing script."

  End If

End Sub

See Also

Copyright © 2020. Hexagon Manufacturing Intelligence – Metrology Software, Inc. All Rights Reserved.