Creating and Displaying Maplet Applications in Command-Line Maple - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Maplets : Maplets/CommandLine

Creating and Displaying Maplet Applications in Command-Line Maple

  

You can use the Command-Line version of Maple to create and display Maplet applications.

 

Description

Examples

Description

• 

To use Maplet applications in the Command-Line version, enter the Maplet application code at the Maple prompt as you would for Maple code.

• 

Alternatively, using a text editor, enter a Maplet application definition into a text file.  Save the text file with a .mpl extension.

  

Depending on your operating system, you can run the .mpl file by:

  

* Double-clicking it from your file browser or

  

* Entering maple and the filename as an argument at the command line.

  

The Maple code is executed in Command-Line Maple. If a Maplet application is defined with the Maplet[Display] command specified, it is displayed.

Examples

Copy the following Maplet application code into your Command-Line session.  Press ENTER.

withMaplets[Elements]:

mapletMapletClick a Button:,ButtonOK,Shutdowntrue,ButtonCancel,Shutdown:

resultMaplets[Display]maplet

Save the following example as a .mpl file.  From your file browser, double-click the .mpl file you created.

useMapletsinuseElementsinmapletMapletWindow'title'=Hilbert Matrix,Dimension: ,TextField['TB1']10,Target format: ,DropDownBox['DDB1']MATLAB,MatrixMarket,delimited,File name:,TextField['TB2']hilmat,ButtonOK,Shutdown'TB1','DDB1','TB2',ButtonCancel,Shutdownend use;resultDisplaymapletend use:ifresultandresult3thentrynparseresult1end try;iftypen,'integer'thenExportMatrixresult3,LinearAlgebra:-HilbertMatrixn,outputoptions='datatype'=float[8],'target'=convertresult2,'symbol'end ifend if:

See Also

Maplets[Display]

Maplets[Elements]

Maplets[Examples]

Maplets[Tools]

MapletViewer

Overview of Maplet Applications

 


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam