﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>A1VBCode Forums / Visual Basic .NET / .NET Programming (VB 2010 or earlier)  / How to show DataTable in ReportViewer contral as Local Report (.rdlc) / Latest Posts</title><generator>InstantForum.NET v4.1.1</generator><description>A1VBCode Forums</description><link>http://www.a1vbcode.com/vbforums/</link><webMaster>forums@a1vbcode.com</webMaster><lastBuildDate>Thu, 09 Feb 2012 04:20:36 GMT</lastBuildDate><ttl>20</ttl><item><title>How to show DataTable in ReportViewer contral as Local Report (.rdlc)</title><link>http://www.a1vbcode.com/vbforums/Topic27871-9-1.aspx</link><description>&lt;img align="absmiddle" src="http://www.a1vbcode.com/vbforums/Skins/Classic/Images/EmotIcons/w00t.gif" border="0" title="w00t"&gt;&lt;BR&gt;Hello Gurus,&lt;P&gt;I have the a DataTable and I want to show it in Report, For this I do this...&lt;/P&gt;&lt;P&gt;1. Create a DataTable "tbl" and add data into it.&lt;BR&gt;2. Create a DataSet1 (DataSet1.xsd) having table ("tblEmp") with same defination as in my DataTable "tbl"&lt;BR&gt;3. In a Form Draw ReportViewer1 control and a button(Button1) and create following code in &lt;BR&gt;   Button1_click event&lt;/P&gt;&lt;P&gt;&lt;pre&gt;        Me.ReportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local&lt;BR&gt;        Me.ReportViewer1.LocalReport.ReportPath = "C:\Report1.rdlc"&lt;BR&gt;        Me.ReportViewer1.LocalReport.DataSources.Add(New Microsoft.Reporting.WinForms.ReportDataSource("tblEmp", tbl))&lt;BR&gt;        Me.ReportViewer1.RefreshReport()&lt;/pre&gt;&lt;/P&gt;&lt;P&gt;&lt;BR&gt;The report show only report columns without any data. [My tbl has 3 rows]&lt;/P&gt;&lt;P&gt;&lt;BR&gt;Please tell me where I am wrong ?&lt;/P&gt;&lt;P&gt;Thanks&lt;BR&gt;</description><pubDate>Fri, 03 Jul 2009 05:00:03 GMT</pubDate><dc:creator>angel0in</dc:creator></item></channel></rss>
