.rdlc reporting bound to Object Data Source in Three layer Application
Asked Answered
D

1

1

i have the following situation, i have a Reporting layer(stand alone) in asp.net application(NOT website, this means NO App_Code folder exists), and i want just to create Object Data Source to take an Object in a separate layer(lets say from Data Access Layer), and then to use that Object Data Source to create a report, i have spent my whole day working around that, tons of work around's and articles on the web, but does not mention what i really want to do, any answer is appriciated...

just to make things more clear here, assume the following:

i have a solution with the follwoing layers,

  • UI
  • Reporting(has NO Employees object) just a reference
  • Business Logic
  • Data Access Layer(Employees-->GetEmployees(),

all i need is as mentioned above, i want to create Object Data Source from Reporting layer, to take Employee object from DAL, and then use it's GetEmployees method to be added to report, i think its more clear now, since also Reporting layer has NO App_Code folder.

Dorolisa answered 3/10, 2009 at 22:1 Comment(3)
Just curious if you've made any progress with this? I'd love hear what you did to accomplish this.Avenue
@Avenue actually not much, it was annoying to have such an issue not solved until now, because i was in a hurry to know and to implement, at last all i did is using DataSet in the same Web.UI LayerDorolisa
It's a shame this question never got answered, this is exactly what I'm wanting to do. A very rare topic indeed, definitely a custom-rolled solution.Badman
A
0

The way Ive been doing it is by creating a class that has a property of type List. I dhave a method called LoadReport(params......) in this class where I would call GetEmployess to populate my property.

I would then add a new Dataset in the report designer, selecting to bind to Object, and selecting the class i created. Once finished the dataset will allow you to expand the List property where you can drag different fields onto the designer.

Ive done this in VS2008, currently attempting in VS2010

Autarky answered 16/6, 2010 at 0:40 Comment(3)
Correction: Within the Datasources toolbar just click Add New Data Source, select OBJECT, select the report class you created specific to that report with exposed propertiesAutarky
thought it is a long time since posted this question, but i will try it, and will feed you with the results :)Dorolisa
Thx it works fine, i used the same methodology by adding a new Folder to ASP.NET Web Application (Called it ReportsLogic) which consists of classes designed for each report as the classes you posted above.Dorolisa

© 2022 - 2024 — McMap. All rights reserved.