469,913 Members | 2,352 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,913 developers. It's quick & easy.

Runtime Crystal reports in VS.NET-C# (using CRAXDDRT20) problem

Hi all,

I'm trying create dynamic reports by Crystal Reports engine distributed with
VS.NET. I know there is only lite version without native support to do this,
but I've found another way via using CRAXDDRT20 library (Crystal Reports
..NET ActiveX Designer Design and Runtime library).

But I've problem with adding table by passing ADO recordset:

loCRGenerator = new CRAXDDRT20.ApplicationClass();
loReport = loCRGenerator.NewReport();

ADODB.RecordsetClass loADO = new ADODB.RecordsetClass();

foreach (DataColumn loColumn in aoDataGrid.CurrentDataTable.Columns)
{
loADO.Fields.Append(loColumn.ColumnName, ADODB.DataTypeEnum.adVarChar,
50, ADODB.FieldAttributeEnum.adFldMayBeNull);
}

loADO.Open(Missing.Value, Missing.Value, ADODB.CursorTypeEnum.adOpenDynamic,
ADODB.LockTypeEnum.adLockBatchOptimistic, 0);
loReport.Database.Tables.Add("", Type.Missing, loADO, Type.Missing,
"p2smon.dll", Type.Missing, Type.Missing, Type.Missing, Type.Missing,
Type.Missing); <-- here raises error :-(

Error message says: "Type mismatch" ...

Please can You help me? Or exist another way how to do this there?

Thanks
Nov 15 '05 #1
0 2736

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Raghu | last post: by
reply views Thread by Dr. Indera | last post: by
1 post views Thread by Bob | last post: by
2 posts views Thread by =?Utf-8?B?UGF1bA==?= | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.