|
|
A macro that lets you rename the currently
opened file without using the traditional steps
of (1) saving the file, (2) closing it, (3) renaming it with
Windows Explorer, then (4) opening it again.
How it works
Since clicking on File>Save As automatically
creates a copy of the current file (and leaves
you in the opened copy), the Renamer macro -
- renames the open file (with File>Save
As), then
- immediately deletes the original file from
your disk, leaving the current (renamed) file open, then
- returns the cursor at its original location,
ready for further document editing
-- all in one step.
Notes and Tips
- Since the macro deletes the
originally opened file after it makes a renamed copy, a warning
message was added to the macro code in v1.01: "Delete the
originally opened file <name>...?". You can remove
this warning and/or the initial pop-up message ("Renaming
current file...") in the redlined User Modification Area. Simply
open the macro file like any other document, set either or both
variables (vDisplayMessage1, DisplayMessage2) to 0 (zero),
then click the Save & Compile button on the macro toolbnar.
- If the current file has not yet been saved
with a name, the Save As dialog lets you name and save it. Hence,
you can play the macro in any document, even a newly opened and
unnamed one.
- For convenience, you can assign this macro
to a toolbar button, keystroke combination, or menu. See "Three easy ways to play macros,
load programs, type keystrokes, or use built-in WordPerfect features".
Other file-processing macros of interest
- MultiSav - Macros to help automate saving documents
- SaveCopy - A macro that saves the current file and then immediately
makes a copy on another hard drive, floppy disk, or other removable
disk
- Shredder - "Shred" (delete from disk) the currently
open file
Disclaimer |