PC-DMIS 2021.2 Object Library
CADModelFile Method
See Also  Example  Send Topic Feedback | See Object Hierarchy Chart
PCDLRN ActiveX DLL > CadModel Object : CADModelFile Method

Glossary Item Box

Description

This method returns the full path to the file name of the CAD model that you imported into the measurement routine.

Syntax

Visual Basic
Public Function CADModelFile() As String

Return Type

String value of the full pathway to the model file. If the measurement routine does not have a CAD model, this string is empty.

Example

This example displays the name of the CAD model in a message box that is associated with the current measurement routine.
Example (Visual Basic)Copy Code
Dim DmisApp As Object
Dim DmisPart As Object
Dim MyModel As Object


Sub Main
  Set DmisApp = CreateObject("PCDLRN.Application")
  Set DmisPart = DmisApp.ActivePartProgram
  Set MyModel = DmisPart.CadModel
  MsgBox "The CAD model name " & MyModel.CADModelName
	
End Sub

See Also

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