/build/static/layout/Breadcrumb_cap_w.png

VBscript XML Custom Action

I posted a thread a few weeks ago and now looking at a suggestion from Jmcfadyen I have been trying to get something going here. Maybe someone can help me out.

As suggested by Jmcfadyen, I check out Wix. Wix is good but I don't think it's good for what I'm doing. Wix more or less creates a .MSI for you based on a supplied .XML file. It's nice but I think I'll stick with Wise for this.

I have a bit of code such as this for example:


<?xml version='1.0'?>
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
<Product Id='{929E7AB8-2E59-4C9B-B15A-C89D1E7BFC47}' Name='My package.msi' Language='1033'
Version='38.8.5.1' Manufacturer='Microsoft Corporation' UpgradeCode="{5381834C-1044-47B0-A6D7-B93B5974B2F4}">
<Package Description='My Package'
Comments='TEST INSTALL'
Manufacturer='Microsoft Corporation' InstallerVersion='200' Compressed='yes' />
<Feature Id='Features' Title='Features' Level='1'>
<ComponentRef Id='Registry' />
</Feature>

<Directory Id='TARGETDIR' Name='SourceDir'>
<Component Id="Registry" Guid="{387A0463-20A4-4FEB-8070-A00C43C304E2}">
<RegistryValue Id="registry506" Root="HKLM" Key="SOFTWARE\PRC\Chinese_Food" Name="General Tsao" Value="Combo" Type="string"/>
<RegistryValue Id="registry589" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="Driver" Value="[SystemFolder]SQLSRV32.dll" Type="string"/>
<RegistryValue Id="registry590" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="Description" Value="Restarea1" Type="string"/>
<RegistryValue Id="registry591" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="Server" Value="Restaraunt" Type="string"/>
<RegistryValue Id="registry592" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="Database" Value="buffet" Type="string"/>
<RegistryValue Id="registry593" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="Language" Value="us_english" Type="string"/>
<RegistryValue Id="registry594" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="LastUser" Value="SYSTEM" Type="string"/>
</Component>
</Directory>
</Product>
</Wix>


This code would reside as a .XML file located in the same directory as the .msi / transform. I'd like to have a custom action read these values and populate the registry keys. Keep in mind, the above was target specifically for Wix.

This line:
<RegistryValue Id="registry594" Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="LastUser" Value="SYSTEM" Type="string"/>

Could probably be narrowed down to something such as:
<Root="HKLM" Key="SOFTWARE\ODBC\ODBC.INI\BOB" Name="LastUser" Value="SYSTEM" Type="string"/>

So how do I get this going? I know there has to be a way, I just can't seem to find it. :(

0 Comments   [ + ] Show comments

Answers (4)

Posted by: anonymous_9363 13 years ago
Red Belt
0
First, Jon has an XML class posted somewhere for reading and writing XML elements and attributes.
Second, there is a dedicated 'Scripting' forum on AppDeploy. A moderator may well move this thread there.
Posted by: Secondlaw 13 years ago
Third Degree Blue Belt
0
ORIGINAL: VBScab

First, Jon has an XML class posted somewhere for reading and writing XML elements and attributes.
Second, there is a dedicated 'Scripting' forum on AppDeploy. A moderator may well move this thread there.

Ahhh but where?

Moderator, please move to scripting. I apologize for this.
Posted by: anonymous_9363 13 years ago
Red Belt
0
It's been a while so thanks http://www.lmgtfy.com/?q=mcfadyen+xml+class
Posted by: jmcfadyen 13 years ago
5th Degree Black Belt
0
hmm i don't seem to have access to upload attachments any more.

I actually meant you can use Wise to import the WiXCA

it is just a dll if you like I can mail you a idt with some samples and the CA etc.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ