## UpdateExternalReference

### Introduced

v6.0

### Description

Sets all paths of external references used by a given target. The paths to feed into this command are a comma delimited string of all the paths used.
Note: UpdateExternalReference does not work for expressions, please use EditExpr to update expressions.

### Scripting Syntax

    oString = UpdateExternalReference( Target, InputObjs );

### Return Value

String

### Parameters

Parameter | Type | Description
--- | --- | ---
Target | String | Parameter value to retrieve. Default Value:
InputObjs | String | Paths to set.

### Examples

#### JScript Example

    /*

    	Demonstrates how to use UpdateExternalReference to update all external reference paths

    */

    var coll = GetExternalReferences();

    for ( var i=0; i<coll.Count; i++ ) {

    	var paths = InspectExternalReference( coll(i) );

    	paths = paths.replace( "ModelA", "ModelB" );

    	UpdateExternalReference( coll(i), paths );

    }

### See Also

GetExternalReferences InspectExternalReference