From: Steph on
Hello,

I"m working with some application development(crm solution) with require to
generate programmaticaly rdlc file at runtime, but i don't know how to do.
online help of CSharp.Net provides tutorial on how to generate rdl file but
not rdlc files.

Any Help will be welcome.

thank in advance.

Stephane

From: Alberto Poblacion on
"Steph" <ntsteph(a)hotmail.com> wrote in message
news:u985eS0pKHA.5696(a)TK2MSFTNGP04.phx.gbl...
> I"m working with some application development(crm solution) with require
> to generate programmaticaly rdlc file at runtime, but i don't know how to
> do. online help of CSharp.Net provides tutorial on how to generate rdl
> file but not rdlc files.

The rdlc files are just XML. If you know the contents that you want to
produce, a simple XmlTextWriter can be used to write the file. The difficult
part is, of course, knowing what is the XML that you need to write in order
to produce a specific report. One way to do this is to create a sample
report in the designer and then look at the xml that is generated. make some
changes in the designer and then see how they affect the xml. In this way,
you will soon find out what you should write into the file.

As an alternative, if you already know how to create a .rdl, then you
can simply rename it to .rdlc and it should work. The main difference
between them is that the .rdlc doesn't care about the datasource contained
in the .rdl, because in the case of the .rdlc it is your code that provides
the data. But the ReportViewer should ignore those parts and just work with
the renamed .rdl.