GUI Command Methods
The GUI command methods correspond to the GUI Commands node in the editor tree. The editor tree is displayed in, for example, the Choose Commands to Run section in the Settings window for a button object in the Application Builder.
Downloads a file to the client. See also the section “Example code”. The method returns a boolean that indicates if the operation was successful or not.
Example Code
For examples of how to use fileSaveAs, see the Introduction to Application Builder. This method is frequently needed for saving files in general.
You can create an application that saves and exits automatically by running the following lines of code, for example, after solving:
saveModel(model,"C:\\COMSOL\\file.mph");
exit();
or
saveModel(model, "common:///file.mph");
exit();
This is useful in a COMSOL Server setting since using exit() in this way will free up any licenses that are checked out.