APLX Help
: System Classes
: Methods
: Save
|
|
![]() |
The 'Save' method |
Argument: Character vector, or a two-element nested vector Valid for: Chart, Image, RichEdit ImageThe Save method for an Image takes a character vector argument, which is the file name under which you want to save the image. You can specify the format in which you want to save it by setting the format property before calling this method, or alternatively allow the format to be determined automatically from the file extension. If you specify an empty vector for the filename, APLX displays a dialog allowing the user to specify the file name and type. ChartThe Save method for a Chart causes the chart to be saved to a graphics file. The argument is the full path of the file to be written. Alternatively, it can be an empty vector, in which case a standard file dialog is displayed to allow the user to choose the name. The optional second parameter can be 0, meaning write the file using a platform-specific vector graphics format, or 1, meaning write the file in a bitmap format, or 2, meaning write the file in Scalable Vector Graphics (SVG) format. The default is 0. If you want to save the chart in a format not supported by the Chart object, for example as a GIF, you can do this using an Image object. To do this, you need to read the bitmap property of the Chart, write this to the bitmap property of the Image, set the Image format, and then call the Save method of the Image. RichEditThe Save method causes APLX to save the contents of a RichEdit control to a file. The argument can be either a character vector containing the pathname of the file you wish to save to, or a nested vector where the first element is the file name and the second is a file type code. A type code of 0 (or omitting the type code) indicates that the contents should be saved as a plain text file. Under Windows, a type code of 1 can be used, to indicate that the contents should be saved as a Rich Text (.rtf) file, with embedded formatting information. Under MacOS, a type code of 2 means save as Styled text. If you specify an empty vector as the file name, a dialog is displayed to allow the user to specify the file name and type. |
|
APLX Help
: System Classes
: Methods
: Save
|
Copyright © 1996-2010 MicroAPL Ltd