ReNamer:Pascal Script
Jump to navigation
Jump to search
The PascalScript Rule in ReNamer uses Pascal Script. To exploit the full power of ReNamer, you will have to know basic pascal scripting.and then learn how to use it in ReNamer.
- The basic Pascal script syntax is covered in this excellent tutorial.
- The specific variables, procedures and functions that are defined within ReNamer are explained in this article
A few quick tips:
- Changes to the FileName variable will be treated as changes to the New Name of the File.
- The FilePath constant holds the original path to the file. It allows you to access the file directly.
- ReNamer supports UDFs (User-Defined Functions) and also importing of external functions from DLLs.
- All manipulations with the FileName variable should be done using Unicode functions, i.e. WideString type should be used instead of an ordinary String type. This will allow ReNamer to handle filenames in non-English scripts (Cyrillic, Asian, German, French, etc.)
Warning: Do not override ReNamer's built-in variables, types and functions. Warning: Some of the functions are able to alter your file system, so use them with caution!
Reference
In a nutshell
- How to rename a file (using the FileName variable)
- How to skip extention (Basic FileName utilities)
- How to convert the filename to ALLCAPS (the WideUpperCase function)
- How to operate on words (Unicode string-handling routines)
- How to serialize files (Basic conversion routines)
- How to initialize variables
- How to create interactive dialogs (let the user decide)
- How to work with folders and paths (FilePath)
- How to break the script execution