SAP Crystal Reports runtime for.Net 4.0 (64-bit) closed This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly. The latest version of SAP Crystal Reports runtime engine for.NET Framew is 13.0.5.891, released on. It was initially added to our database on. The most prevalent version is 13.0.0.99, which is used by 16% of all installations.

Symptom

Addin For Crystal Reports 2011 built for .NET framework 4.0 fails to load, this worked in previous builds

Environment

Cause

Crystal Reports 2011 Designer has a dependency on .NET 2.0 Framework

Resolution

Create a crw32.exe.config file and paste in the following:

<?xml version ='1.0'?>
<configuration>
<startup useLegacyV2RuntimeActivationPolicy='true' >
<supportedRuntime version='v4.0' />
</startup>
</configuration>

Save this to file to where crw32.exe is located:

C:Program Files (x86)SAP BusinessObjectsSAP BusinessObjects Enterprise XI 4.0win32_x86

Start up the Report Designer and open the View, Tool Bars menu and check on the External Command.

What this does is tell crw32.exe to use 4.0 framework. Found this MS kbase article:

According to MSDN: http://msdn.microsoft.com/en-us/library/w4atty68.aspx

If your application is built with the .NET Framework 4 but has a dependency on a mixed-mode assembly built with an earlier version of the .NET Framework, it is not sufficient to specify the .NET Framework 4 in the list of supported runtimes. In addition, in the <startup> element in your configuration file, you must set the useLegacyV2RuntimeActivationPolicy attribute to true.

Keywords

Crystal Reports 2011, addins, .NET framework 4.0 , KBA , BI-RA , Reporting, analysis, and dashboards , BI-DEV-NET , BI Software Development Kits (SDKs) - .NET or Other , Problem

Product

SAP Crystal Reports 2011 ; SAP Crystal Reports, developer version for Microsoft Visual Studio

Symptom

  • This sample allows the report designer to set localized string values
  • Attached zip file contains sample C# .NET User Function Library source code as well as a sample report

Environment

Resolution

  • To use this UFL you need to register it with VS .NET
  • Use the regasm command line tool (C:WindowsMicrosoft.NETFrameworkv2.0.50727RegAsm.exe or C:WindowsMicrosoft.NETFramework64v4.0.30319RegAsm.exe)
  • This UFL only works with Crystal Reports 2008 Service Pack 1 and higher
  • For more details see the readme.txt file included in the attached zip file

Also Note:

To change the Class Name so the function name (DotNetSampleClass) is not listed in Crystal Report Designer do the following:

  1. Click on the View menu in .NET IDE and select Show Class View.
  2. Then right click on the class and select Rename.
  3. The delete all but 'CRUFL'
  4. Click the OK button and yes to the next prompt to confirm the name change.
  5. Do the same for the 'Class Test' and change it to something like 'Fnt'.

Now you will see the function named: Fnt StringLength.

To be able to use the UFL in CR Designer you need to tell the Designer to use the same framework by doing the folowing:

To see this new UFL in Crystal report Designer do the following:

  • Crystal Report Designer 2011/2013 is a 32 bit app so the UFL MUST be compiled in x86 mode. If you plan to use the UFL in a 64 bit application then you need a separate 64 bit version:
  • Copy the file and for CR 2008 place it in this folder:
  • C:Program Files (x86)Business ObjectsBusinessObjects Enterprise 12.0win32_x86
  • C:Program Files (x86)SAP BusinessObjectsCrystal Reports for .NET Framework 4.0CommonSAP BusinessObjects Enterprise XI 4.0win32_x86
  • CR for VS is the only 64 bit runtime we have except for BI 4.x also may require it. Depending on the CR Processing Server it may need the 64 bit UFL and 32 bit UFL.

For 32 bit App:

  • C:Program Files (x86)SAP BusinessObjectsCrystal Reports for .NET Framework 4.0CommonSAP BusinessObjects Enterprise XI 4.0win32_x86
  • C:Program Files (x86)SAP BusinessObjectsSAP BusinessObjects Enterprise XI 4.0win32_x86

64 bit App:

  • C:Program Files (x86)SAP BusinessObjectsCrystal Reports for .NET Framework 4.0CommonSAP BusinessObjects Enterprise XI 4.0win64_x64
  • C:Program Files (x86)SAP BusinessObjectsSAP BusinessObjects Enterprise XI 4.0win32_x64

To be able to set Crystal Report Designer to use the same Framework you created the UFL in you must tell CR Designer whcih one to use by doing the following:

Create a file called:

crw32.exe.config

And paste this into it:

<?xml version ='1.0'?>

<configuration>

<startup useLegacyV2RuntimeActivationPolicy='true' >

<supportedRuntime version='v4.0' />

</startup>

</configuration>

Change the 'supportedRuntime version' to what ever framework you are compiling your UFL in.

Save this file into the same location as crw32.exe:

For CR 2011/2013:

C:Program Files (x86)SAP BusinessObjectsSAP BusinessObjects Enterprise XI 4.0win32_x86

And for CR 2008:

C:Program Files (x86)Business ObjectsBusinessObjects Enterprise 12.0win32_x86

Now you should see your functions in the list in CR Designer.

For CR 2020 you need a 64 bit version of the UFL:

Create a file called:

crw64.exe.config

Reports

And paste this into it:

<?xml version ='1.0'?>

<configuration>

<supportedRuntime version='v4.0' />

</startup>

</configuration>

4.0

Change the 'supportedRuntime version' to what ever framework you are compiling your UFL in.

Save this file into the same location as crw64.exe:

For CR 2020:

C:Program Files (x86)SAP BusinessObjectsSAP BusinessObjects Enterprise XI 4.0win64_x64

See Also

  • Blog; Creating Crystal reports User Function Libraries (UFL) with Visual Studio .NET
  • For information on creating a C++ UFL see KBA 1603381 - How to create a C++ UFL using the new Unicode UFL interface in Crystal Reports 2008 & later

Keywords

.NET UFL UNICODE String UFL user function library visual studio VS , KBA , BI-DEV-NET , BI Software Development Kits (SDKs) - .NET or Other , How To

Sap Businessobjects Crystal Reports For .net Framework 4.0

Product

Crystal Reports 2008 V1 ; SAP Crystal Reports 2011 ; SAP Crystal Reports 2013 ; SAP Crystal Reports 2016 ; SAP Crystal Reports 2020 ; SAP Crystal Reports, developer version for Microsoft Visual Studio

Crystal Reports Runtime Windows 10

Attachments

Sap Crystal Reports Runtime Engine

CRUFLDotNetSample.zip