Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Need to display field total but... Post Reply Post New Topic
Author Message
Getch
Groupie
Groupie


Joined: 26 Dec 2008
Online Status: Offline
Posts: 47
Quote Getch Replybullet Topic: Need to display field total but...
     Posted: 07 Apr 2011 at 7:10am
Hi All,
 
I have a field that always nets to zero but I need to display a total of either the Pos or Neg amount.
 
I've tried a few things but can not get a it to work. I've tried creating a shared variable but have not had any success.
 
Is there an easier way than a shared variable?
 
Basically, my subreport shows account summary info, contributions, withdrawals, earnings and I want to show new loans.
 
The loans field consists of transactions which will always net to a zero total.
Newbie reports
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 07 Apr 2011 at 7:26am
make 2 formula fields to split positve from negative then sum each of those
Negativeonly
if field<0 then field else 0
Positiveonly
if field>0 then field else 0
 
SUM(@positiveonly)
SUM(@negativeonly)
IP IP Logged
Getch
Groupie
Groupie


Joined: 26 Dec 2008
Online Status: Offline
Posts: 47
Quote Getch Replybullet Posted: 07 Apr 2011 at 8:01am
Well darn...dont I feel like an idiot....
 
That works perfectly DBlank. Thanks!
 
I had tried to filter out the pos and sum all in one formula...which was not working out so I abandond and tried the shared variable....
Newbie reports
IP IP Logged
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