Scripting Actions PDF Print
Written by Administrator   
Monday, 11 May 2009 09:42

Ghost Installer 4.0 came up with plenty of new features. One of the most exciting new features in Ghost Installer 4.0 is the ability to create custom scripting actions. In old 3.x versions the software developer could gain full control over the installation process, but it was impossible to show custom dialogs or perform tuning up installed application without writing a special plug-in, which was not acceptable for many customers. Now those days are gone and Ghost Installer 4.0 presents new tool in the sidebar - Scripting actions. This new feature does not require extra plug-in, all functions are implemented directly in the installer engine, so if you use scripts, your installation does not become hundreds of kilobytes bigger. What capabilities does scripting in Ghost Installer offer?

During the installation process the installer engine sends various events to the plug-ins. This events report different information about stages of installation or request plug-ins to perform some action. Instead of creating a plug-in that would react on these events, you can create custom scripting actions that can implement as complex functionality, as you like. Powerful functionality of Scripting Actions is based on a set of functions, implemented in the installer engine and the plug-ins. For example, using DownloadFile function you can make WebDeploy plug-in download a file from the Internet and save it to disk, NetFrameworkInstalled function returns 1 if requested version of .Net Framework is installed on user's machine and so on. All engine and plug-ins events, functions and operators are described in Online Help, short help on functions is available in Expression builder - a handy tool to build scripts.

Scripting actions also have conditional expressions, a customizable loop construction and a switch-case operator. Creating scripts is also available in User Interface, so you can create custom dialogs and show them at any place of installation. Moreover, each control also has a set of events, which can be handled by scripts:

Using scripts you can modify any property of any control or a window or show another dialog, which makes it possible to create fully interactive installations.

Scripting capability is a built-in feature for the installer engine, no extra plug-in is required to perform scripting actions. Almost all functions used in scripts are also built in the engine (in all commercial editions), only specific functions are based on the plug-ins. It is also possible to create a plug-in that would make its functions available for scripting actions and user interface events.

Installer engine also provides a wide set of system variables, which can tell a lot about the end-user's system, like OSVersion, OSPlatform and so on.

In addition to scripting actions, Ghost Installer has the condition mechanism. Every installation item (files, registry entries, shortcuts, components, packages, dialogs) have conditions. A condition is the expression that is evaluated before this item is processed. If the condition returns 1 as a result, the item is processed, otherwise the item is not processed. This enables, for example, to copy correct versions of files for NT and non-NT systems, if a file has a condition "%OSPlatform%='NT'" it will only be copied if end-user has NT-based Windows.

Summary:

Ghost Installer features a very flexible and powerful scripting system, which makes it possible to solve complex installation tasks, tune application after installations, gather information about user and so on.

 

 

Benefits:
Demo version users can build setup projects using Custom User Interface, WebDeploy (limited) and other Ghost Installer extensions, but the setup projects cannot be used for commercial purposes.

Home - News - Products - Shop - Download - Community - Articles - Tech Support - Company
Privacy Policy - Legal Notice

Copyright © 1999-2012 Ethalone Solutions, Inc. All rights reserved.