Numbershark and Wordshark

From Wiki

Revision as of 20:34, 23 August 2010 by Mr wordshark (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to:navigation, search

Numbershark and Wordshark Network 4.05 MSI deployment

Everything here about Numbershark is the same for Wordshark.

For some reason Numbershark 4 doesn't have an MSI installer, or really any installer, just copy the files, add a shortcut, and in the target/working dir of the shortcut add the path to the share on the network.


  • Install Wix 3
  • Copy numbershark-programs and numbershark-public to a folder called SourceDir
  • Run: "\Program Files\Windows Installer XML v3\bin\heat.exe" dir SourceDir -cg Numbershark -out ns001a.wxs -gg -dr INSTALLDIR

It might complain about Java 1.4 dlls and things, shouldn't matter: eg: heat.exe : warning HEAT5150 : Could not harvest data from a file that was expected to be a SelfReg DLL: C:\wix\SourceDir\numbershark-programs\bin\NPOJI610.dll. If this file does not support SelfReg you can ignore this warning. Otherwise, this error detail may be helpful to diagnose the failure: Exception has been thrown by the target of an invocation..

This creates a .wix fragment. Put that fragment between:

<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="">
    <Product Id="{GUID}" Language="1033"
       Manufacturer="White Space" Name="Numbershark"
       UpgradeCode="{GUID}" Version="">
        <Package Compressed="no" InstallerVersion="200" InstallScope='perMachine' />
        <Directory Id="TARGETDIR" Name="SourceDir">
	  <Directory Id="ProgramFilesFolder">
	     <Directory Id="INSTALLDIR" Name="Numbershark" FileSource="SourceDir">
	  <Directory Id="ProgramMenuFolder">
    	    <Directory Id="ApplicationMenuFolder" Name="Maths"/>
	  <Directory Id="NetworkShared" Name="." />
        <Feature Id="ProductFeature" Level="1" Title="Numbershark">
          <ComponentGroupRef Id="Numbershark" />
	  <ComponentRef Id="ApplicationShortcut" />	
        <Media Id="1" />
	<CustomAction Id="SetNetworkShared" Directory="NetworkShared"
              Value="\\domain.local\share$\SharedData\Numbershark-shared" />
          <Custom Action="SetNetworkShared" After="CostFinalize">Not Installed</Custom>
      <DirectoryRef Id="ApplicationMenuFolder">
        <Component Id="ApplicationShortcut" Guid="{GUID}">
            <Shortcut Id="ApplicationStartMenuShortcut" 
                  Name="Numbershark Network"
                  Description="Numbershark Network Version"
                  WorkingDirectory="NetworkShared" Advertise="no" />



Because I don't quite know how to use WiX, find sections for numbershark-programs and -public

        <DirectoryRef Id="someGUID">
            <Directory Id="dir4A916887A737B027BC358ACFA851914C" Name="numbershark-programs" />


        <DirectoryRef Id="someGUID">
            <Directory Id="dir46DD2280A050F96FFEC29E7974D3141B" Name="numbershark-public" />

and change "someGUID" to "INSTALLDIR"

  • Change the name in ApplicationMenuFolder from Maths to whatever submenu you want it to appear in in the start menu.
  • Change the share in CustomAction Id="SetNetworkShared" Directory="NetworkShared" Value="\\domain.local\share$\SharedData\Numbershark-shared" to your shared dir.
  • Save the new file as numbershark.wxs
  • Run "\Program Files\Windows Installer XML v3\bin\candle.exe" numbershark.wxs

this will complain about ICE18, 38, 43 and 60, ignore.

  • Finally run "\Program Files\Windows Installer XML v3\bin\light.exe" numbershark.wixobj to create the MSI
  • Copy the MSI and the SourceDir (or Numbershark, not sure) dir to your DFS share, deploy via GPO.

Notes: It would be better to make the MSI then have an MST to change the share path, then you can give the MSI to others, and the GUIDs wouldn't need to change.

The Custom Action is needed for some reason to make the workingdir point to a unc path, that's also why it can't be an advertised shortcut