Symptom
- Advanced logging for the Crystal Reports .NET SDK.
- How to turn on/off crpe logging for the Crystal Reports .NET SDK?
Environment
- Crystal Reports for Visual Studio 2010
- Crystal Reports 2008
- Crystal Reports XI R2
- Crystal Reports XI R1
- Crystal Reports 10
- Visual Studio 2003, 2005, 2008
Resolution
Crystal Reports .NET Logging
When regular troubleshooting fails you may need to dive deeper into an issue to find out what is going on. You can turn on CRPE logging in the CR .NET SDK by modifying a few registry keys.
How to turn logging on and off
The first thing to keep in mind is that logging slows down performance. Logging is not recommended for long term use. It can result in a very slow reporting system and it creates large log files on the system.
- Create two .reg files called logging-on.reg and logging-off.reg using Notepad.
- Copy the text from the appropriate section below into each .reg file and save it.
- Copy the .reg files to the system where you need to do your logging.
- Double click the logging-on.reg file and merge the contents into the registry.
- Restart IIS, service, or Windows application you are monitoring. Note: The logging won't work if the Crystal runtime files are already in memory.
- Run the application until the point of failure, or your error message.
- Locate the .log files in your temp directory.
- Windows XP; C:\Documents and Settings\<user>\Local Settings\Temp
- Windows Vista, 7, Server 2008; C:\Users\<user>\AppData\Local\Temp
- Windows Server 2008 running Visual Studio IDE creates a subfolder \2 ( in my case ) that VS uses as a temp folder. This is where the log files are located
- They will be named according to the application. For example, if your app is called mySlowReport.exe - the log files will be named:
- mySlowReport.crpe.bkgrnd.log
- mySlowReport.crpe.Diagnostics.log
- mySlowReport.crpe.functions.log
It is best to open and analyze these log files in Excel.
Note: This logging doesn't work for the bundled version of the CR .NET SDK for Visual Studio .NET 2003.
Descriptions for the registry key values:
Destinations:
0 - No logging
1 - Log output to file
2 - Log output to the debug output window
3 - Log output to file and to the debug output window
Positions:
0 - No Logging
1 - Log on function entry
2 - Log on function exit (default)
3 - Log on function entry and exit
LogErrorsOnly:
0 - Output all log messages.
1 - Output only log messages associated with an error (non-zero return)
Crystal Reports for Visual Studio 2010 Note The log file extension created by Crystal for Visual Studio 2010 is .GLF. Enable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.bkgrnd] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.diagnostics] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.functions] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.bkgrnd] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.diagnostics] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.functions] Disable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.bkgrnd] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.diagnostics] [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.functions] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.bkgrnd] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.diagnostics] [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports\Logging\crpe.functions]
|
Crystal Reports 2008 Enable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.functions] Disable Logging
[HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 12.0\Crystal Reports\Logging\crpe.functions\] |
Crystal Reports 2011/2013/2016 Enable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.functions] Disable Logging [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite XI 4.0\Crystal Reports\Logging\crpe.functions] |
Crystal Reports XI R2 Enable Logging
[HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.functions\] Disable Logging
[HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.5\Crystal Reports\Logging\crpe.functions\] |
Crystal Reports XI R1 Enable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.functions\] Disable Logging
[HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\Logging\crpe.functions\] |
Crystal Reports for Visual Studio 2005 Enable Logging Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.functions\] Disable Logging
[HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.bkgrnd\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.diagnostics\] [HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\10.2\Crystal Reports\Logging\crpe.functions\] |
Keywords
trace tracing , KBA , BI-DEV-NET , BI Software Development Kits (SDKs) - .NET or Other , How To