Heaventools

   English English  Deutsch Deutsch

Sample Scripts Library

Sample scriptsTo help you understand how Resource Tuner Console works and to meet various needs, we have created a set of sample scripts and corresponding test applications. These scripts can serve as templates that you can adjust for your project.

Don’t like writing scripts? We have that covered. All you need to do is replace the file names and paths to the source and destination locations according to your requirements.

After installing Resource Tuner Console, you can access these examples in the Demo Scripts folder, located within the installation directory. The Demo folder contains 12 subdirectories, each housing sample scripts and their associated executable files.

The Complete Illustrated Step-by-Step Guide To Using Scripts
How To Write Scripts

All sample scripts are pre-configured, and you can run them without any additional setup. To execute a sample script, simply select one of the provided .BAT files within the Demo folders. The script will apply the defined changes to a test EXE file, and the resulting modified file will be saved in a directory named "Release", which will be located within the same directory containing the script.

If you want to explore the script code for any specific example, click on the corresponding script name below to view the code and delve deeper into the functionality and implementation.


Script Name Description

Edit Icons

This script demonstrates how to add or replace icons in the test application. It allows you to replace the main icon with new icons sourced from an .ico file, including a 256x256 PNG-compressed icon (Vista icon). Additionally, the script organizes the added icons in the correct order and outputs the changes in the Resource Tree to a log file.

Edit Strings

Shows how to modify String Tables and Message Tables using string literal values from an external Unicode text file. It allows you to efficiently edit multiple entries across several files at once and repeat the editing process as needed.

Edit Manifest

The script shows how to:
  – Add or replace an UAC manifest;
  – Replace icons in the executable with icons from an .ico file which contains more than one image;
  – Add a 256x256 PNG-compressed icon (a Vista icon);
  – Sort out the added icons in the correct order;
  – Output the changes in the Resource Tree to a log file.

Edit Version Information

Shows how to update or add version variables to all EXE, DLL, or RES files in a folder.

Localize Version Information

Shows how to make an application display the Version Information in different languages based on the user's locale:
  – Modify the existing String File Version Information;
  – Create a copy of the Version Information for the German language;
  – Optionally, it sets every field in the PE file header, export, and resource sections to the adjusted TimeDate stamp.

Edit Custom GIF

Shows how to edit common data types that stored as custom resources, such as major graphic files (.GIF, .PNG, .JPG), sound (.WAV, .MIDI) and video (.AVI) files, or binary files (.CAB, TYPELIB, etc):
  – Add or replace a non-standard resource (GIF) sourced from .gif file;
  – Add or replace a Cursor from .cur file;
  – Optionally, it sets a new ImageBase value.

Edit Bitmap

Shows how to add or replace a Bitmap Image (.BMP) in the test application.

Process Folder

This script illustrates how to batch process the contents of a directory containing mixed EXEs and DLLs. It patches all the files with given file extensions (EXE, DLL, SYS, RES, etc) in the source directory.

Big Demo Script

This script shows how to:
  – Modify the String Table using a definition file;
  – Add a new String Table;
  – Modify the Message Table;
  – Update the Version Info resource;
  – Create a copy of the resource with another language;
  – Output the resource tree to a log file;
  – Save the entire file's resources as a resource DLL.

 

To view the changes made to the test EXEs, you can open them using Resource Tuner GUI.

 


Get Started with a 60-Day Free Trial

Download ResTuner Console and learn how it can make you more productive.

Download Resource Tuner Console Resource Tuner Console runs on all versions of Windows in use today: from 11 to XP, both 32-bit and 64-bit.