Report Design
 Crystal Reports Forum : Crystal Reports .NET 2003 : Report Design
Message Icon Topic: Adding Dynamic fields Post Reply Post New Topic
Author Message
netcrguy
Newbie
Newbie


Joined: 17 Aug 2007
Location: United States
Online Status: Offline
Posts: 3
Quote netcrguy Replybullet Topic: Adding Dynamic fields
    Posted: 17 Aug 2007 at 10:47am
Hi Brian,
 
Do you have any samples on how to add a new field to a report from the code. I would really appreciate your help on this. I'm stuck with this problem for few days now and need to resolve it asap. I'm using crystal reports.net 2003.
Thanks.
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 20 Aug 2007 at 11:12pm
You can't add new fields. However, you can use a SQL statement which uses the ALIAS keyword to create a list of generic field names. That allows you to create dynamic SQL which swaps out the fields and change their order. If you want to drop a field, just replace it with an empty string. it's still not perfect, but it gets most people what they want.
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
netcrguy
Newbie
Newbie


Joined: 17 Aug 2007
Location: United States
Online Status: Offline
Posts: 3
Quote netcrguy Replybullet Posted: 21 Aug 2007 at 8:04am

Thanks Brian for the reply. I also read somewhere that we can do this with Crystal Reports X! Developer. Is this true.

Thanks.
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 21 Aug 2007 at 8:31am
Yes, they added this functionality to the R2 release. I haven't tried it yet, but you do get full CR runtime customization of report objects. This is very exciting b/c people have been wanting this for a long time. It will be a couple months before I can dive into it and write about it for the .NET 2005 book coming out at the end of the year.
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
netcrguy
Newbie
Newbie


Joined: 17 Aug 2007
Location: United States
Online Status: Offline
Posts: 3
Quote netcrguy Replybullet Posted: 22 Aug 2007 at 11:19am

Brian,

I have purchased the CR XI developer release 2 and have started playing around with it. If you know some code from somwhere please give me the link. I will also paste my code here after i've figured out how to do this.
 
Thanks
Thanks.
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 22 Aug 2007 at 1:45pm
Unfortunately, I don't have any code yet. I don't have time to dig into it yet. If you find some code, it would be great to give us a heads-up.
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.