Simulink Reference Previous page   Next Page
open_system

Open a Simulink system window or a block dialog box

Syntax

Description

open_system('sys') opens the specified system or subsystem window, where 'sys' is the name of a model on the MATLAB path, the fully qualified pathname of a model, or the relative pathname of a subsystem of an already open system (for example, engine/Combustion). On UNIX, the fully qualified pathname of a model can start with a tilde (~), signifying your home directory.

open_system('blk'), where 'blk' is a full block pathname, opens the dialog box associated with the specified block. If the block's OpenFcn callback parameter is defined, the routine is evaluated.

open_system('blk', 'force'), where 'blk' is a full pathname or a masked system, looks under the mask of the specified system. This command is equivalent to using the Look Under Mask menu item.

open_system('blk', 'parameter') opens this block's parameter dialog box.

open_system('sys', 'mask') opens this block's mask.

open_system('blk', 'OpenFcn') runs this block's open function.

open_system('sys', 'replace') the window of the parent system with the window of the subsystem opened by this command.

open_system('sys', 'reuse') uses the parent system's window to display the subsystem opened by this command.

Example

This command opens the controller system in its default screen location.

This command opens the block dialog box for the Gain block in the controller system.

Suppose that mymodel contains a masked subsystem, A, and a block, B, whose OpenFcn contains the following lines:

Then opening block B causes both the parameter dialog box for B and the mask dialog box for A to appear.

See Also


Previous page  new_system replace_block Next page

© 1994-2005 The MathWorks, Inc.