Connecting Tech Pros Worldwide Forums | Help | Site Map

Dynamic report - Crystal Report (C# .Net)

Climber
Guest
 
Posts: n/a
#1: Nov 15 '05
Hello,

I want to now how to do a dynamic report with Crystal
Report (C# .Net), the number of colum and row are
different each time because they depend of my data base.

Thanks

Climber

Ignacio Machin
Guest
 
Posts: n/a
#2: Nov 15 '05

re: Dynamic report - Crystal Report (C# .Net)


Hi,

With the .NET version of CR you cannot create the report dynamically.

The number of rows is not important, as the report struct does not change
with this, the number of columns are the real concern.

Cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"Climber" <developer@sogescom.net> wrote in message
news:a92b01c38110$45c0f800$a601280a@phx.gbl...[color=blue]
> Hello,
>
> I want to now how to do a dynamic report with Crystal
> Report (C# .Net), the number of colum and row are
> different each time because they depend of my data base.
>
> Thanks
>
> Climber[/color]


[GHO]
Guest
 
Posts: n/a
#3: Nov 15 '05

re: Dynamic report - Crystal Report (C# .Net)


I want to know how to change the DataBase path on
runtime ,same database same table but deferent
path "report with Crystal"

[color=blue]
>-----Original Message-----
>Hi,
>
> With the .NET version of CR you cannot create the report[/color]
dynamically.[color=blue]
>
> The number of rows is not important, as the report[/color]
struct does not change[color=blue]
>with this, the number of columns are the real concern.
>
>Cheers,
>
>--
>Ignacio Machin,
>ignacio.machin AT dot.state.fl.us
>Florida Department Of Transportation
>
>"Climber" <developer@sogescom.net> wrote in message
>news:a92b01c38110$45c0f800$a601280a@phx.gbl...[color=green]
>> Hello,
>>
>> I want to now how to do a dynamic report with Crystal
>> Report (C# .Net), the number of colum and row are
>> different each time because they depend of my data base.
>>
>> Thanks
>>
>> Climber[/color]
>
>
>.
>[/color]
Ignacio Machin \( .NET/ C# MVP \)
Guest
 
Posts: n/a
#4: Nov 15 '05

re: Dynamic report - Crystal Report (C# .Net)


Hi,

I haven;t do that, but I think that if you change the ConnectionInfo of the
report it can be done, in fact in the code I posted you can see that I set
the ConnectionInfo and assign it to all of the tables I'm using, so in
theory you could even have different data sources for different tables in
the same report,
I include the code here again as I do not remember if I posted it on this
particular thread.

Hope this help,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

ConnectionInfo crConnectionInfo = new ConnectionInfo();

crConnectionInfo.ServerName = "127.0.0.1";

crConnectionInfo.DatabaseName = "CTP";

crConnectionInfo.UserID = "test";

crConnectionInfo.Password = "test";

foreach (CrystalDecisions.CrystalReports.Engine.Table table in
reportDocument1.Database.Tables)

{

TableLogOnInfo crTableLogonInfo = new TableLogOnInfo();

crTableLogonInfo.TableName = table.Name;

crTableLogonInfo.ConnectionInfo = crConnectionInfo;

crTableLogonInfos.Add( crTableLogonInfo);

table.ApplyLogOnInfo( crTableLogonInfo);

}

CrystalReportViewer1.LogOnInfo = crTableLogonInfos;

CrystalReportViewer1.ReportSource = reportDocument1;


"[GHO]" <yousefk@taux01.nsc.com> wrote in message
news:1eb101c38ff8$aa67da20$7d02280a@phx.gbl...[color=blue]
> I want to know how to change the DataBase path on
> runtime ,same database same table but deferent
> path "report with Crystal"
>
>[color=green]
> >-----Original Message-----
> >Hi,
> >
> > With the .NET version of CR you cannot create the report[/color]
> dynamically.[color=green]
> >
> > The number of rows is not important, as the report[/color]
> struct does not change[color=green]
> >with this, the number of columns are the real concern.
> >
> >Cheers,
> >
> >--
> >Ignacio Machin,
> >ignacio.machin AT dot.state.fl.us
> >Florida Department Of Transportation
> >
> >"Climber" <developer@sogescom.net> wrote in message
> >news:a92b01c38110$45c0f800$a601280a@phx.gbl...[color=darkred]
> >> Hello,
> >>
> >> I want to now how to do a dynamic report with Crystal
> >> Report (C# .Net), the number of colum and row are
> >> different each time because they depend of my data base.
> >>
> >> Thanks
> >>
> >> Climber[/color]
> >
> >
> >.
> >[/color][/color]


Closed Thread