Showing posts with label WIX. Show all posts
Showing posts with label WIX. Show all posts

Monday, 9 January 2012

error LGHT0132: The assembly file 'somedll.dll' appears to be invalid. Please ensure this is a valid assembly file and that the user has the appropriate access rights to this file.

When we try to build a wix project that refers an C++ dll, we may face below error

error LGHT0132: The assembly file 'somedll.dll' appears to be invalid.  Please ensure this is a valid assembly file and that the user has the appropriate access rights to this file.

It is strange cos it happens only in few machines. Following below steps might resolve the error

1. Open your *.wixproj file for editing.
2. Add <SuppressAssemblies>True<SuppressAssemblies> under a 'PropertyGroup' that has relevant 'Light' settings.


example:

  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
   
<OutputPath>bin\$(Configuration)\</OutputPath>
    <IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
    <WixVariables>BannerBitmap=..\..\Branding\TrustDigital\Installer\topimage.bmp;WixUILicenseRtf=..\..\Branding\TrustDigital\Installer\terms-of-use.rtf;WixUIDialogBmp=..\..\Branding\TrustDigital\Installer\leftsideimage.bmp</WixVariables>
  </PropertyGroup>





   I identified above as my relevant PropertyGroup becauase it contains 'WixVariables'(LIGHT related task), so i just need to insert <SuppressAssemblies>True<SuppressAssemblies> into this PropertyGroup.

Friday, 10 June 2011

Wix force install new msi

msiexec caches the installer, hence if you want to force executing new installer pls use

msiexec /fc installer.msi

This might be useful, because while developing you might have set installation conditions wrong, which might fire during un-installation as well, hence might block from doing so.

like




Above condition happens no matter what whether you are trying to install or uninstall.