2 Replies - 486 Views - Last Post: 06 December 2012 - 02:16 PM Rate Topic: -----

#1 GeneralCrackers  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 05-October 12

Report Viewer Problem

Posted 06 December 2012 - 01:53 PM

Hello everyone,

I am working on a project for a class that requires reports to be displayed in a Report Viewer using Visual Studio 2010. I am using a local database. The problem that I am having is that after I link the .rdlc file to the Report Viewer and the data set and try to test run it none of the data is displayed. Any expressions are displayed as "#Error" and plain data leaves blanks. All the formatting and labels are displayed. Why does this happen and what should I do to fix it? I tried using data from previous assignments (even basic queries without any joins) and I also tried using a sample database and report from Microsoft's walkthroughs, but both give me the same result. Thanks in advance.

Is This A Good Question/Topic? 0
  • +

Replies To: Report Viewer Problem

#2 tlhIn`toq  Icon User is offline

  • Please show what you have already tried when asking a question.
  • member icon

Reputation: 5432
  • View blog
  • Posts: 11,645
  • Joined: 02-June 10

Re: Report Viewer Problem

Posted 06 December 2012 - 02:01 PM

There is no single answer for something like this besides "You coded something wrong."

We have no idea what code you wrote, what objects you're using, if your data is being loaded in a method then evaporating when the the method goes out of scope, if you're using numerous variables of the same name in different methods and thinking they are the same instance...

You're calling a mechanic and saying "My car won't drive. What's wrong with it?"
Was This Post Helpful? 0
  • +
  • -

#3 GeneralCrackers  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 05-October 12

Re: Report Viewer Problem

Posted 06 December 2012 - 02:16 PM

At this point I haven't done any actual coding for this portion of the project. I started a Reporting C# project, it automatically generated a Report Viewer in Form1, I clicked Data, then Add New DataSource, added my database including all tables, then clicked Project then Add Existing Item, and selected my .rdlc file. After that I chose the report in the Report Viewer and also linked the dataset. In the Report.rdlc design view I can see the formatting and data of the report, but when I click Debug it displays nothing for the data and #Error for any expressions, but the layout and labels remain. There are no errors displayed in the error log and the database and report worked fine before this. Is that clearer? I could take a screenshot of what displays when I click Debug if that would help.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1