Friday, March 9, 2012

How to add fields to Report Designer from a Web Service or something equivalent?

Hello,

I am trying to add some fields to my report (Using SQL Server 2005 Reporting Services, Visual Studio 2005).

As of now I can only use fields from one of my tables, or use functions within SQL DBMS. However, sometimes I wish to do more complicated things which can not be done (or at least I don't know how to do) withing SQL DBMS.

I wish to write a C# function (Web service) which takes a bunch of parameters and spits out some text. Is it possible to add a field to the report which calls this Web service, sends a bunch of parameters and displays the result of the function.

If not, Is there any way at all to manipulate some data using C# and display the result in the report.

Thanks in advance,

Any help is much appreciated

Amir

If what you are asking is "Can report items be dynamically added to a report"? then the answer is yes.

You can dynamikcally add fields to a report by loading the RDL via a memory stream to the report viewer control in local mode. Prior to loading the RDL you will need to parse the XML in order to add the the field.

No comments:

Post a Comment