SetOverride

Description:              This statement allows the overriding of OpCodes with a specified script module within a  static module tree.

Warning:                   This statement should be used by advanced users only.  Effective use of this function requires a thorough understanding of VTS programming.

Returns:                    Nothing

Usage:                   Script

Format:                      SetOverride(TargetModule, OpCode, [Override, Recursive])

Parameters:              TargetModule { Module }  { required }  { no default: }

                                                Any expression that can be resolved to the module value that will be modified.

                                    OpCode    { numeric }  { required }  { no default: }

                                                Any numeric value that represents the built-in function to replace.

                                    Override    { Module }  { optional }  { no default: }

                                                The module value that will be called in place of OpCode. If invalid or missing, any existing overrides of OpCode in TargetModule will be removed.

                                    Recursive    { numeric }  { required }  { default: True }

                                                If true, the OpCode will be replaced with calls to the override function in all of the child modules of the target module.

Comments:               Adds the ability to override a built-in function inside a module with a  call to a different module. The purpose of this feature is to facilitate testing of modules that use time, streams, etc. so that these functions can be overridden with more controllable inputs.

See Also:

GetOverrides