X-Setup Pro

Select your language: 

XQDC Ltd.
X-Setup Pro - the mother of all tweakers

X-Setup Pro SDK

Scripting Reference

X-Setup allows externals programs (like Scripts or even other Applications) to use any function normally used only inside a plugin. This can be done with any script (VBScript, Jscript, ActivePearl etc.) or programming language that is able to handle COM objects.

Starting with X-Setup Pro 9.0, X-Setup does now longer register its COM components to the registry of your computer; it uses Registry-Free COM. Because of this you first need to execute xqdcXSPCompReg.exe before you can use Scripting. Please see www.x-setup.net/forum/showthread.php?t=1212 for details.

Once this has been done, you can start using X-Setup Pro Scripting. First, you need to create an object of type type xqdcXSPEngine.Plugin (all examples in this document are based on VBScript executed by the Windows Scripting.

set obj=WScript.CreateObject("xqdcXSPEngine.Plugin")

You can need to ask for the permission to actually retrieve the object with all X-Setup Pro functions with the following call:

set ii=obj.RegisterExternalAccess(“[path to script file goes here]”)

This will raise a question dialog which the user needs to accept or reject. If the call is accepted you can execute all functions that are listed inside the Function Reference, e.g:

Call ii.RegWriteValue("HKCU\Software\Test\XSP External Access\Value1","my data from vbs",1)

Any call you make will have the same options applied as currently configured for X-Setup Pro. For example, if the user has enabled “Safe Mode”, any call you make that alters something will result in a Yes/No question displayed to the user. If “Safe Mode” is not activated, this won’t happen.

Also, the Restore Log will also be fully in effect. For example the above example call will result in an entry saved within the Restore Log. The user can later on easily revert this change made by using the Restore Log player.

Please note that, although you can call any function, some of them will have no effect. For example, the call to Disable() will have no effect whatsoever since it is used to disable the user-interface of a plugin. Since there is no user-interface displayed, nothing will happen.