Print Page | Close Window

Providing XML as datasource in RAS

Printed From: Crystal Reports Book
Category: Crystal Reports .NET 2003
Forum Name: Data Connectivity
Forum Discription: How to connect to data sources and export reports
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=2089
Printed Date: 05 May 2024 at 5:18pm


Topic: Providing XML as datasource in RAS
Posted By: Nipun45
Subject: Providing XML as datasource in RAS
Date Posted: 21 Jan 2008 at 4:12am

Hello,

Im trying to generate report from an existing .rpt file using RAS and providing xml as its datasource. My problem is to connect report table with its datasource.

I want to do something like following but in RAS (Using ReportClientDocument object).

Dim datasetFromXml As New System.Data.DataSet
' Load dataset from xml
ByVal reportDoc As CrystalDecisions.CrystalReports.Engine.ReportDocument
' Load report Document from .rpt file

Dim i As Int32 = 0

For
Each reportTable As CrystalDecisions.CrystalReports.Engine.Table In reportDoc.Database.Tables

       Dim dataTable As New System.Data.DataTable = datasetFromXml.Tables(i)
reportTable.SetDataSource(dataTable)
i += 1
Next
 
I would really appreciate any help. Thank you


-------------
Regards,
Nipun



Print Page | Close Window