Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: dynamically removing fields? Post Reply Post New Topic
Author Message
Allany
Newbie
Newbie


Joined: 03 Aug 2009
Online Status: Offline
Posts: 12
Quote Allany Replybullet Topic: dynamically removing fields?
    Posted: 06 Aug 2009 at 1:19am
Hi all,
 
I was wondering how/if it is possible to dynamically remove fields from a report based on meeting certain conditions and the section "auto fitting"?
 
Example, if i have rows A-G in a details section, and I wanted D-G to be "removed", I would also want the section to shrink to size.
 
I can in the supress formula create a formula to supress it when the condition is met,but the field cells seems to still exist.
 
Any advice would be useful.
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 06 Aug 2009 at 6:07am
if you're using CR XI, you can put a formula in the Size and Position that will shrink it...I haven't tried shrinking, but I have done moving, and here are the few caveats for moving (probably apply to shrinking as well, but I'm not sure).
 
1) size is in pixels ( I think), but to create a new size you need to divide the 'final' size by 1440
2) the sizes given by you, are the 'changes' to the original size.  so getting a result of 1/4 inch, means changing the size by 1/4 inch (larger, since it is positive.
 
HTH
IP IP Logged
Allany
Newbie
Newbie


Joined: 03 Aug 2009
Online Status: Offline
Posts: 12
Quote Allany Replybullet Posted: 06 Aug 2009 at 8:35am
hi,
 
yes using CRXI, so there really isn't a way for it to be "removed" as such, but just reduced to give the impression it's not there?
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 06 Aug 2009 at 1:59pm
Crystal doesn't allow the adding or removing of fields from the report.  You can hide them, you can move them, and you can resize them, but you can't delete them.
 
If you are hiding something and you don't want the space left vacant, you can move other fields, or you can have alternative display sections and conditionally show or suppress them so that there isn't empty space, but these are all just tricks for making the display look nice.
 
So, yes, you give the impression that a field is not there, but you cannot actually remove it.
IP IP Logged
Allany
Newbie
Newbie


Joined: 03 Aug 2009
Online Status: Offline
Posts: 12
Quote Allany Replybullet Posted: 07 Aug 2009 at 12:54am
thanks for the information, i thought as much along those lines.
 
cheers, time to investigate in how to shrink them. :)
IP IP Logged
Allany
Newbie
Newbie


Joined: 03 Aug 2009
Online Status: Offline
Posts: 12
Quote Allany Replybullet Posted: 07 Aug 2009 at 8:36am
Hi, need some more help.  It seems I don't have a X-2 formula creation option for my size and position.  Only for the position.  I am using CRXI.  Any reason why I don't have that option?
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 10 Aug 2009 at 7:00am
Hmm... I don't use this option too often (only once or twice).  I have buttons for X: and Width: ....  If your Width is missing, maybe you have....I was going to say Auto Grow on, but that only changes height not width.
 
Well, you can still do what you want, just move the field far enough to the left to be off the report, or you can move it the beginning of the line and suppress it.
 
Like I said, I haven't used this option that often, so I don't really know what the issue might be.
 
Sorry I can't be of more help.
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.