mdlIObject GetGlobalAddressFromLocalAddress

Gets the global address from the specified local address.

Syntax

mdlIObject_handle GetGlobalAddressFromLocalAddress entity_varname

Application

MotionView Tcl Query

Description

This command obtains the global address given a local address. In other words, it returns the full variable name of an entity given a ‘entity_varname’ (with regards to a different System). For example, if there exists a hierarchy MODEL.sys_0.sys_1.sys_2.p_0, the Global Address of sys_2.p_0 w.r.t MODEL.sys_0.sys_1 will be MODEL.sys_0.sys_1.sys_2.p_0.

Inputs

entity_varname
The variable name of an entity whose global address is desired.

Example

To get the global address from a specified local address:
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 AddSystemFromNewInlinedDef sys0_handle System sys_0 "\"SYSTEM 0\"" def_sys_0
sys0_handle AddSystemFromNewInlinedDef sys1_handle System sys_1 "\"SYSTEM 1\"" def_sys_1
sys1_handle AddSystemFromNewInlinedDef sys2_handle System sys_2 "\"SYSTEM 2\"" def_sys_2
sys2_handle GetGlobalAddressFromLocalAddress p_0
sys0_handle ReleaseHandle
sys1_handle ReleaseHandle
sys2_handle ReleaseHandle
myModelName ReleaseHandle
myClientName ReleaseHandle
myWindowName ReleaseHandle
myPageName ReleaseHandle
myProjectName ReleaseHandle
mySessionName ReleaseHandle

Errors

Returns the global address if successful. If there is an error, an error code will be returned.