Free Support Forum - aspose.com

Aspose.Words without .Net Framework 2.0 via Com

Hi,

i tryed to make first tests under Windows 10 with Aspose.Words. So i made a clean Windows 10 Installation. There is no Framework 2.0 installed, only 4.6

Registering Aspose.Words with Regasm V4.0 works without any error. But when i try to instanciate a new Aspose.Words.ComHelper, i get a Automation Error under VBA. It only works when i install the V2.0 Framework.

Is it posibly to run Aspose.Words without installing the V2.0 Framework?

Greets

Hi Matthias,


Thanks for your inquiry. Please try to debug the code and post complete error message for our reference. Did you use the /codebase option in the Regasm.exe command line? Also, please make sure you are using correct Regasm according to your target platform:

32bit - C:\Windows\Microsoft.NET\Framework\v4.0.30319\RegAsm.exe
64bit - C:\Windows\Microsoft.NET\Framework64\v4.0.30319\RegAsm.exe

Best regards,

Hi,

i have no target plattform. I used the 32 bit Regasm.exe with the /codebase parameter. I am using Microsoft Access 2010 32 bit to call it via COM. The Regasm tells me it was successfull, only a few warnings about visibility of some functions. I also can set a reference from VBA to Aspose.Words. This won´t be possible, if the registration failed. But when trying to initiate a new instance of ComHelper Class, the only error message i get is automation error, without any description. The only Code i use is:

Dim m_ComHelper as Aspose_Words.ComHelper
Set m_ComHelper = New Aspose_Words.ComHelper

You can try this code also in Excel or Word.

Greets

Hi Matthias,


Thanks for the additional information. Please try registering Aspose.Words.dll to Global assembly Cache using Gacutil.exe tool and then register assembly again using Regasm.exe. I hope, this helps.

Best regards,

Hi,

sorry, but it don´t work. It only works when i install the v2.0 Framework. Is there a part in Apose.Words that needs exlicitly the 2.0 Framework?

Greets

Hi Matthias,


Thanks for your inquiry. We are in coordination with product team to get answer pertaining to your queries. Soon you will be updated with the required information.

Best regards,

Hi Matthias,


Thanks for being patient.

When regasm.exe adds entries to the registry, it writes CLR version for each class entry. The CLR version is taken from assembly manifest (from Assembly.ImageRuntimeVersion property). For the Aspose.Words.dll it is v2.0.50727. When the Aspose.Words assembly is loaded by COM, .NET Framework of the version 2.0 is not found and the 80131700 error occurs.

If we change CLR version in the Aspose.Words.ComHelper class entry in the registry to v4.0.30319 (changing only this entry is enough if document is created by ComHelper instance), no error occurs and all works well.

So, we can propose you the following solutions;

  • Simply Install .NET Framework of version 2.0.
  • Change CLR version for the Aspose.Words.ComHelper class in the registry in two {C51B173B-EC00-377A-BCF4-DE09FE876EED} class ID entries.

Hope, this helps.

Best regards,

Hi Matthias,


Regarding WORDSNET-12064, our product team has completed the work on your issue and has come to a conclusion that this issue and the undesired behaviour you’re observing is actually not a bug in Aspose.Words. So, we have closed this issue as ‘Not a Bug’. Please see details in my previous post.

Best regards,