Std SaveCopy

From LabRPS Documentation
Revision as of 06:14, 25 July 2024 by LabRPS (talk | contribs) (Created page with "{{Docnav |SaveAs |SaveAll |Std File Menu |IconL=Std_SaveAs.svg |IconR=Std_SaveAll.svg |IconC=Labrps.svg }} {{GuiCommand |Name=Std SaveCopy |MenuLocation=File → Save a Copy... |Phenomena=All |SeeAlso=Std SaveAs, Std Save }} ==Description== The '''Std SaveCopy''' command saves a copy of the active document under a new file name. ==Usage== # Select the {{MenuCommand|File → Image:Std_Sa...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Arrow-left.svg Previous: Std SaveAs.svg SaveAs
Next: SaveAll Std SaveAll.svg Arrow-right.svg

Std SaveCopy.svg Std SaveCopy

Menu location
File → Save a Copy...
Phenomena
All
Default shortcut
None
Introduced in version
-
See also
Std SaveAs, Std Save

Description

The Std SaveCopy command saves a copy of the active document under a new file name.

Usage

  1. Select the File → Std SaveCopy.svg Save a Copy... option from the menu.
  2. Enter a filename in the dialog box.
  3. Press the Save button.

Options

  • Press Esc or the Cancel button to abort the command.

Scripting

See also: Autogenerated API documentation and LabRPS Scripting Basics.

To save a copy of a document use the saveCopy method of the document object.

import LabRPS
from pathlib import Path

# The folder and filename we will use:
fld = 'D:/testfiles/'
fnm = fld + 'testCopy.RPSStd'

# Make sure fld exists:
Path(fld).mkdir(parents=True, exist_ok=True)

doc = LabRPS.newDocument()
doc.saveCopy(fnm)


Arrow-left.svg Previous: Std SaveAs.svg SaveAs
Next: SaveAll Std SaveAll.svg Arrow-right.svg