Solved

How to print subtotal in body of report, based on last occurance of item number

Posted on 2009-07-06
8
230 Views
Last Modified: 2012-05-07
Hello,

I use Dynamics GP 10, and Crystal Reports 2008 to print my sales documents (via Forms Printer from Accountable Software).  I'd like to be able to print a subtotal in the body of the sales quote form, based on the last occurance of a certain item number.

For example, I have a large quote that references several areas of a building.  I would like to show a subtotal for each area.  The last line item in each area is a part number called "ROOM".  This part number signifies the end of the equipment for that room.

Any help you can provide is greatly appreciated!
0
Comment
Question by:michaelleffew
  • 4
  • 2
  • 2
8 Comments
 
LVL 17

Expert Comment

by:pssandhu
Comment Utility
Do you have area numbers, ids or some kind of unique key value for each area. I would use that field to group my report and add a subtotal in that group.
However, from your explanation it does not seems that way. From top my head (not tested) I am think of having a unique identifier for each group. So to accompalish that you can have something like this:
1. Create a formula and call it what ever you want and put this text in there:
WhilePrintingRecords;
Shared Numbervar val;
IF {Table.PartNumberField} <> "ROOM" Then val
ELSE val := val+1;
val
2. Place the formula in your detail section and create a group using this formula.
3. This formual should create an incrementing unique id for each group and should group each area. Add your subtotal to this group.
Hope this helps.
P.
0
 
LVL 100

Expert Comment

by:mlmcc
Comment Utility
You can't group on printtime formulas like that since they are calculated after grouping is done.

Try this.

Put the subtotal on the report.
Right click it
Click FORMAT OBJECT
Click the COMMON TAB
Click the FORMULA button to the right of SUPPRESS
{Your Field} = "Room"

If you are trying to do a subtotal for just that room it may require other formulas.

mlmcc
0
 

Author Comment

by:michaelleffew
Comment Utility
Thanks for your feedback!  I am trying to do a subtotal for just that room.  I would need subtotal to show at the end of each room.  Each quote has several rooms in it.
0
 

Author Comment

by:michaelleffew
Comment Utility
so, i was playing around with the running total field suggested by mlmcc, and got it to look pretty good, with one exception...  I've told it to reset the total based on the item number "ROOM".  Now, the total shows 0.00.  Is there a way to tell it to reset after the item number "ROOM" ?

Thanks for your continued help!!
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 17

Expert Comment

by:pssandhu
Comment Utility
Can you not declare a local variable, assign the value to the local variable, reset the total and print the local variable.
P.
0
 

Author Comment

by:michaelleffew
Comment Utility
i'm afraid I don't follow :(
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
Comment Utility
You can't based on that record since the running total will update before you display the value.

mlmcc
0
 

Author Comment

by:michaelleffew
Comment Utility
Thank you for your help!!
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

On Sep 22nd 2014 Microsoft released Update Rollup 1 for Microsoft Dynamics CRM 2013 Service Pack 1 and back in July Update Rollup 3 was released.  So we now have:   Update Rollup 1Update Rollup 2Update Rollup 3Service Pack 1Update Rollup 1 for S…
Automatically creating a Trello card using data from a Microsoft Dynamics CRM record turned out to be an easy project that yielded great results.  Here's how I did this for an internal team at General Code.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now