mdlIObject GetSourceFile

Obtains information about the source file for the assembly created in the model.

Syntax

mdlIObject_Handle GetSourceFile type

Application

MotionView Tcl Query

Description

This command obtains information about the source file for the assembly created in the model.

Inputs

type
The type of source file requested. Valid arguments are: DATA and DEFINITION.

Example

You need to load an assembly prior to running this example.

To get the source file of a given assembly:

hwi OpenStack
hwi GetSessionHandle mySessionName 
mySessionName GetProjectHandle myProjectName 
set activePageNum [myProjectName GetActivePage]
myProjectName GetPageHandle myPageName $activePageNum
set activeWinNum [myPageName GetActiveWindow]
myPageName GetWindowHandle myWindowName $activeWinNum
myWindowName GetClientHandle myClientName 
myClientName GetModelHandle myModelName 
myModelName GetChildHandle myAssembly assem_0
set temp [myAssembly GetSourceFile DATA];
tk_messageBox -message "The Source of the Assembly is: $temp";
myAssembly ReleaseHandle;
myModelName ReleaseHandle
myClientName ReleaseHandle
myWindowName ReleaseHandle
myPageName ReleaseHandle
myProjectName ReleaseHandle
mySessionName ReleaseHandle
hwi CloseStack

Errors

Returns the file name including the path and Library name.