Troubleshooting: Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel...'

Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
This error can occur when there are multiple versions of the .NET Framework on the computer that is running IIS, and IIS was installed after .NET Framework 4.0 or before the Service Model in Windows Communication Foundation was registered.

For Windows 7 and Windows Server 2008, use the ASP.NET IIS Registration Tool (aspnet_regiis.exe,) to register the correct version of ASP.NET. For more information about the aspnet_regiis.exe, see ASP.NET IIS Registration Tool.

To register the correct version of ASP.NET

  1. On the computer that is running Microsoft Dynamics NAV Web Server components, open a command prompt as an administrator as follows:
    1. From the Start menu, choose All Programs, and then choose Accessories.
    2. Right-click Command Prompt, and then choose Run as administrator.
  2. At the command prompt, type the following command to change to the Microsoft.NET\Framework64\v4.0.30319 folder, and then press Enter.
    cd\Windows\Microsoft.NET\Framework64\v4.0.30319
    
  3. At the command prompt, type the following command, and then press Enter.
    aspnet_regiis.exe -iru
    

Font Size Decreases When Export to PDF in Crystal Report

If barcode size is not what you expect when export to PDF in Crystal Report, you need to look no further for solution.

To fix the bug, just follow steps below by adding 2 registry keys.

1. Select Start > Run. Type regedit and click OK.

2. For Crystal Reports 2008, Expand HKEY_CURRENT_USER\Software\Business Objects\Suite 12.0\Crystal Reports\Export.

For Crystal Reports 11.0, Expand HKEY_CURRENT_USER\Software\Business Objects\Crystal Reports.

For Crystal Reports 10.0, Expand HKEY_CURRENT_USER\SOFTWARE\Crystal Decisions\10.0\Crystal Reports\Export

For Crystal Reports 9,0, Expand HKEY_CURRENT_USER\software\crystal decisions\9.0\Crystal Reports\Export

3. Right-click the Export folder and select New > Key. This creates a new folder. Name the new folder PDF.

4. Right-click the PDF folder and select New > DWORD Value.

5. Name this 'ForceLargerFonts' with no quotes and note that it is case sensitive.

6. Double-click ForceLargerFonts and change the Value data to 1 and click OK.

7. Close all the registry folders and expand the following registry For Crystal Reports 2008, HKEY_LOCAL_MACHINE\Software\Business Objects\Suite 12.0\Crystal Reports.

For Crystal Reports 11.0, HKEY_LOCAL_MACHINE\Software\Business Objects\Suite 11.0.

For Crystal Reports 10.0, HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.0\Crystal Reports

For Crystal Reports 9.0, HKEY_LOCAL_MACHINE\Software\Crystal Decisions\9.0\Crystal Reports

8. Right-click the Crystal Reports folder and select New > Key. Name this key Export.

9. Right-click the Export folder and select New > Key. This creates a new folder. Name this folder PDF.

10. Repeat steps 4 through 6.

11. Close the Registry Editor and restart Crystal Reports.


After adding these two registry keys, Crystal Reports won't have this font size problem any more.


However, if you want to generate barcode in Crystal Reports from IIS server, you need to modify permissions of these registry keys.

IIS security model prevents the application pool identity to read those registry entries by default.

Open Windows application Regedit and browse to

HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Export\PDF

Right click the key and choose “Permissions” from context menu.

Add in default IIS user account. Usually it's IUSR_MachineName.