Component Code - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Getting Started : Menus : Document Menu Bar : Edit Menu : worksheet/documenting/componentcode

Component Code

You can edit or add Maple code to an embedded component to specify an action performed when the embedded component is selected or altered.  This Maple code is edited or added through a Code Editor.

 

Summary of Available Actions for Embedded Components

Editing Embedded Component Code in the Code Editor

Summary of Available Actions for Embedded Components

 Name of Action

Description

Components that Perform This Action

Edit Value Changed Code

perform a specified action when the value of the component is altered.

Rotary Gauge, Volume Gauge,Slider, Meter, Dial

Edit Click Code

perform a specified action when component is clicked

Button, Radio Button, Check Box, Plot

Edit Recording Start Code

performs an action when the recording starts

Microphone

Edit Recording End Code

performs an action when the recording stops

Microphone

Edit Data Available Code

performs an action when data is available from the storage buffer of the recording

Microphone

Edit Dragged Code

performs an action when the mouse is dragged in the plot component

Plot

Edit Drag End Code

performs an action when the mouse is released from dragging in a plot component

Plot

Edit Hover Code

performs an action when the mouse hovers in a plot component

Plot

Edit Select Code

performs an action when the value inside the component is selected

List Box, Combo Box

Edit Content Changed Code

performs an action when the contents in the embedded component change

Data Table, Text Area, Toggle Button

Edit Code

performs an action when the marker is reached during playback

Video

Editing Embedded Component Code in the Code Editor

To edit the component code for an embedded component action:

1. 

Select the embedded component.

2. 

In the Context Panel for the embedded component, click the button for the component action code.

  

(Alternatively, from the Edit menu, select Component Code. A menu is displayed that contains a list of component actions. Select the desired action to modify from the list of available actions.)

3. 

Edit or add your component code in the Code Editor window.

4. 

In the Code Editor window, from the File menu, select Save Code.

For more details, see the help pages for the individual embedded components.

See Also

Code Edit Region

Embedded Components