Tag Archives: using officewriter with .NET 4.0 framework

Error: Could not load file or assembly ‘vsjlib, Version=1.0.3300.0’

Problem

After migrating to the .NET 4.0 Framework, an OfficeWriter application throws the error:

Could not load file or assembly ‘vjslib, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a’ or one of its dependencies. The located assembly’s manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

Solution

OfficeWriter 3.x relies on the J# runtime, so users who have tried using OfficeWriter 3.x with Visual Studio 2010 and the .NET 4.0 Framework have run into issues. This is due to the fact that Microsoft does not have a version of the J# runtime for .NET 4.0.

There are two possible solutions:

#1: Update to OfficeWriter 4.x or later (recommended)

The J# runtime dependency was removed in OfficeWriter 4.0.0, so upgrading to OfficeWriter 4.x or later resolves the issue. We recommend upgrading because all new features and bug fixes are released in the latest version of OfficeWriter.

#2: Downgrade to an earlier version of .NET

For .NET versions 2.0 or 3.0, Microsoft has a J# redistributable package available for 32-bit and 64-bit systems. Microsoft also has a redistributable package of J# for .NET Version 1.1.

NOTE: OfficeWriter 3.x is no longer supported. OfficeWriter Supported Versions Policy