I am creating a C# program where it will display a report that was created using a crystal report. I'm already done with the report. But then, when I tried to view the report in C# it prompted me an error which is "INVALID TLV RECORD". What might be the reason for this? Please help. Thanks.
Code:
private void reportViewer1_Load(object sender, EventArgs e)
{
CRAXDRT.Report rpt = new CRAXDRT.Report();
CRAXDRT.Application app = new CRAXDRT.Application();
rpt = app.OpenReport(Application.StartupPath + "\\Reports\\Pay2Final.rpt", null);
}
Error Message:
try this
The "Invalid TLV Record" error message may appear for the following reasons:
There are missing runtime files on the client computer. Check the Developer Runtime Help file (Runtime.chm) installed with Crystal Reports for a list of required runtime files.
'UFManager.dll' is not distributed to the client computer. Ensure that it is located in the "C:\Program Files\Common Files\Crystal Decisions\2.0\bin" folder.
Crqe.dll is not registered on the client computer. On the taskbar, click the 'Start' button, and then click 'Run'. In the 'Open' text box, type 'regsvr32 '. For example,
regsvr32 "c:\program files\common files\crystal decisions\2.0\bin\crqe.dll"
The report file has become corrupted. For more information, refer to knowledge base article c2005670.
The client computer does not have the 'CommonFiles' registry subkey. To create this registry subkey, follow these steps:
==================== WARNING:
Using the Registry Editor can cause serious problems that may require reinstalling the operating system. Crystal Decisions is not responsible for any problems resulting from using the Windows Registry Editor. Use the Registry Editor at your own risk. It is recommended that you back up the registry before you edit it.
====================
On the taskbar, click the 'Start' button, and then click 'Run'.
Type 'Regedit' in the 'Open' combo-box, and then click 'OK'.
Expand the registry key:
\HKEY_LOCAL_MACHINE\SOFTWARE\Crystal Decisions\9.0\Crystal Reports
Right-click the 'Crystal Reports' folder, select 'New' | 'String Value', and name the new key 'CommonFiles'.
Right-click the 'CommonFiles' subkey, select 'Modify', and type the following value in the 'Value data' text box:
"C:\Program Files\Common Files\Crystal Decisions\2.0\bin\"
or check this link