Sunday, February 12, 2012

Building a report simply by passing a Recordset.

I just attented a Microsoft event where I ask Bernard Wong of Microsoft, if
it was possible to pass a recordset (and some header information) via code
to produce a simple report. He indicated of course and it is well
documented. Does anybody know how to perform this operation, or know where
the documentation on this type of process is?
Byron...The only way I know of how to do this is to read the RDL specification
(posted on Microsoft website). Parse the recordset and make decisions of
things like format, column size and heading. Create the RDL (which is an XML
file but that doesn't mean you don't have to understand the spec). Then you
would have to deploy it with a unique name and then have the client use the
unique name. If using the new controls you could instead use them in local
mode, pass the rdlc and the dataset to the control and have it render it.
The specification is well documented. There are some people who are doing
this. In my mind it is definitely non-trivial.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>I just attented a Microsoft event where I ask Bernard Wong of Microsoft, if
>it was possible to pass a recordset (and some header information) via code
>to produce a simple report. He indicated of course and it is well
>documented. Does anybody know how to perform this operation, or know where
>the documentation on this type of process is?
> Byron...
>|||With RS 2005, the answer to your question is depends on how the report is to
be rendered. If you use the Report Viewer controls in local mode, you can
bind the dataset to the report. If you need to pass the dataset to a
server-based report, you need a custom data extension
(http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B8468707-56EF-4864-AC51-D83FC3273FE5).
--
HTH,
---
Teo Lachev, MVP, MCSD, MCT
"Microsoft Reporting Services in Action"
"Applied Microsoft Analysis Services 2005"
Home page and blog: http://www.prologika.com/
---
"Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>I just attented a Microsoft event where I ask Bernard Wong of Microsoft, if
>it was possible to pass a recordset (and some header information) via code
>to produce a simple report. He indicated of course and it is well
>documented. Does anybody know how to perform this operation, or know where
>the documentation on this type of process is?
> Byron...
>|||I've been trying to do that (RS2005) without much success. I have a rdl file
I have brought in as a rdlc file. I would like to set the datasource to
something in code. If you have any info to point me in the right direction I
would appreciate it. All the examples I see all deal with doing everything
from the designer.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Teo Lachev [MVP]" <teo.lachev@.nospam.prologika.com> wrote in message
news:%23K%23xL8s7FHA.2600@.tk2msftngp13.phx.gbl...
> With RS 2005, the answer to your question is depends on how the report is
> to be rendered. If you use the Report Viewer controls in local mode, you
> can bind the dataset to the report. If you need to pass the dataset to a
> server-based report, you need a custom data extension
> (http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B8468707-56EF-4864-AC51-D83FC3273FE5).
> --
> HTH,
> ---
> Teo Lachev, MVP, MCSD, MCT
> "Microsoft Reporting Services in Action"
> "Applied Microsoft Analysis Services 2005"
> Home page and blog: http://www.prologika.com/
> ---
> "Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
> news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>>I just attented a Microsoft event where I ask Bernard Wong of Microsoft,
>>if it was possible to pass a recordset (and some header information) via
>>code to produce a simple report. He indicated of course and it is well
>>documented. Does anybody know how to perform this operation, or know
>>where the documentation on this type of process is?
>> Byron...
>>
>|||Nevermind, I got it.
--
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Bruce L-C [MVP]" <bruce_lcNOSPAM@.hotmail.com> wrote in message
news:%2393%23RAx7FHA.2092@.TK2MSFTNGP12.phx.gbl...
> I've been trying to do that (RS2005) without much success. I have a rdl
> file I have brought in as a rdlc file. I would like to set the datasource
> to something in code. If you have any info to point me in the right
> direction I would appreciate it. All the examples I see all deal with
> doing everything from the designer.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Teo Lachev [MVP]" <teo.lachev@.nospam.prologika.com> wrote in message
> news:%23K%23xL8s7FHA.2600@.tk2msftngp13.phx.gbl...
>> With RS 2005, the answer to your question is depends on how the report is
>> to be rendered. If you use the Report Viewer controls in local mode, you
>> can bind the dataset to the report. If you need to pass the dataset to a
>> server-based report, you need a custom data extension
>> (http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B8468707-56EF-4864-AC51-D83FC3273FE5).
>> --
>> HTH,
>> ---
>> Teo Lachev, MVP, MCSD, MCT
>> "Microsoft Reporting Services in Action"
>> "Applied Microsoft Analysis Services 2005"
>> Home page and blog: http://www.prologika.com/
>> ---
>> "Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
>> news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>>I just attented a Microsoft event where I ask Bernard Wong of Microsoft,
>>if it was possible to pass a recordset (and some header information) via
>>code to produce a simple report. He indicated of course and it is well
>>documented. Does anybody know how to perform this operation, or know
>>where the documentation on this type of process is?
>> Byron...
>>
>>
>|||Bruce,
Would you mind sharing your success?
Thanks,
Byron...
"Bruce L-C [MVP]" <bruce_lcNOSPAM@.hotmail.com> wrote in message
news:uvi2AQ%237FHA.2716@.TK2MSFTNGP11.phx.gbl...
> Nevermind, I got it.
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Bruce L-C [MVP]" <bruce_lcNOSPAM@.hotmail.com> wrote in message
> news:%2393%23RAx7FHA.2092@.TK2MSFTNGP12.phx.gbl...
>> I've been trying to do that (RS2005) without much success. I have a rdl
>> file I have brought in as a rdlc file. I would like to set the datasource
>> to something in code. If you have any info to point me in the right
>> direction I would appreciate it. All the examples I see all deal with
>> doing everything from the designer.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Teo Lachev [MVP]" <teo.lachev@.nospam.prologika.com> wrote in message
>> news:%23K%23xL8s7FHA.2600@.tk2msftngp13.phx.gbl...
>> With RS 2005, the answer to your question is depends on how the report
>> is to be rendered. If you use the Report Viewer controls in local mode,
>> you can bind the dataset to the report. If you need to pass the dataset
>> to a server-based report, you need a custom data extension
>> (http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B8468707-56EF-4864-AC51-D83FC3273FE5).
>> --
>> HTH,
>> ---
>> Teo Lachev, MVP, MCSD, MCT
>> "Microsoft Reporting Services in Action"
>> "Applied Microsoft Analysis Services 2005"
>> Home page and blog: http://www.prologika.com/
>> ---
>> "Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
>> news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>>I just attented a Microsoft event where I ask Bernard Wong of Microsoft,
>>if it was possible to pass a recordset (and some header information) via
>>code to produce a simple report. He indicated of course and it is well
>>documented. Does anybody know how to perform this operation, or know
>>where the documentation on this type of process is?
>> Byron...
>>
>>
>>
>|||You get a working demo by downloading the chapter 18 source code of my book
(http://www.prologika.com/Books/0976635305/code/).
--
HTH,
---
Teo Lachev, MVP, MCSD, MCT
"Microsoft Reporting Services in Action"
"Applied Microsoft Analysis Services 2005"
Home page and blog: http://www.prologika.com/
---
"Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
news:uUaPKE$8FHA.3416@.TK2MSFTNGP15.phx.gbl...
> Bruce,
> Would you mind sharing your success?
> Thanks,
> Byron...
> "Bruce L-C [MVP]" <bruce_lcNOSPAM@.hotmail.com> wrote in message
> news:uvi2AQ%237FHA.2716@.TK2MSFTNGP11.phx.gbl...
>> Nevermind, I got it.
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Bruce L-C [MVP]" <bruce_lcNOSPAM@.hotmail.com> wrote in message
>> news:%2393%23RAx7FHA.2092@.TK2MSFTNGP12.phx.gbl...
>> I've been trying to do that (RS2005) without much success. I have a rdl
>> file I have brought in as a rdlc file. I would like to set the
>> datasource to something in code. If you have any info to point me in the
>> right direction I would appreciate it. All the examples I see all deal
>> with doing everything from the designer.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Teo Lachev [MVP]" <teo.lachev@.nospam.prologika.com> wrote in message
>> news:%23K%23xL8s7FHA.2600@.tk2msftngp13.phx.gbl...
>> With RS 2005, the answer to your question is depends on how the report
>> is to be rendered. If you use the Report Viewer controls in local mode,
>> you can bind the dataset to the report. If you need to pass the dataset
>> to a server-based report, you need a custom data extension
>> (http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B8468707-56EF-4864-AC51-D83FC3273FE5).
>> --
>> HTH,
>> ---
>> Teo Lachev, MVP, MCSD, MCT
>> "Microsoft Reporting Services in Action"
>> "Applied Microsoft Analysis Services 2005"
>> Home page and blog: http://www.prologika.com/
>> ---
>> "Byron Hopp" <bhopp@.matrixcomputer.com> wrote in message
>> news:uKm0uuS7FHA.2012@.TK2MSFTNGP14.phx.gbl...
>>I just attented a Microsoft event where I ask Bernard Wong of
>>Microsoft, if it was possible to pass a recordset (and some header
>>information) via code to produce a simple report. He indicated of
>>course and it is well documented. Does anybody know how to perform
>>this operation, or know where the documentation on this type of process
>>is?
>> Byron...
>>
>>
>>
>>
>

No comments:

Post a Comment