search cancel

Assembly Type reset to .NET even if the option to rescan assembly attributes is disabled


Article ID: 174659


Updated On:


Symantec Products


When the option to rescan assembly attributes on compile is disabled, if you change the assembly type from .NET to None, the error 2765 occurs when executing the .msi.

Steps to reproduce (must be done on a computer with .NET Framework and Wise Package Studio 7)

  1. Add a .NET assembly to the .WSI.
  2. On the Assembly tab of the File Details dialog, change the Assembly Type to None.
  3. Go to Tools > Options > .NET Assemblies and unmark the option Rescan assembly attributes on compile.
  4. Compile the .WSI.
  5. View the Assembly tab for the file. The Assembly Type is changed back to .NET. This adds an entry into to MsiAssembly table even though no entries are added to the MsiAssemblyName table.
  6. Run the .msi. Error 2765 occurs.


This error occurs because an entry was added to the MsiAssembly table but no entries were added to the MsiAssemblyName table.


This issue has been fixed in Wise Installation Studio/Express 7 SP1.  The fix for this issue will also be included with the next release of Wise Package Studio.

There are several possible workarounds for this issue:
  1. If you want the Assembly type to be None for all files, compile the .wsi on a computer that does not have .NET Framework installed.
  2. If you want the Assembly type to be None for a specific file, open the .msi in Orca and remove the entry for the appropriate file from the MsiAssembly table.
  3. Create a macro that removes entries found in the MsiAssembly table that have no corresponding entry in the MsiAssemblyName table. A sample VBScript that performs this task can be found attached to this article. You may need to modify this VBScript based on your needs. This VBScript should be run on the .MSI after each compile. To run the VBScript use the command <path to MsiAssemblyFix> "<Path to .MSI>".
  4. Running Caspol.exe from the commandline on the machine that is running Windows Installer Editor may correct this issue. Caspol.exe is a tool available from Microsoft's MSDN.

    The required command:
    "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CasPol.exe" -m -ag 1.2 -url file://NetworkMachine/FolderContainingDotNetAssemblies/* FullTrust

For further information on Caspol.exe and how to use the Caspol.exe tool, please see the attached link. 

Related Links

Applies To
Wise Installation Studio 7