Solved

Crystal Report How to Multiply a negative percent

Posted on 2009-04-03
3
871 Views
Last Modified: 2012-05-06
Hello Everyone,

I am working on a report and have a formula which will calculate a goal amount.  This is the formula
({#LYSales} + ({#LYSales} * {@goalpercent}))

This works fine, the problem is when @goalpercent is a negative percentage.... it will just calculate it as a positive percentage.
How can I calculate it as a negative percentage???

Thanks,

Bill

Thanks,

Bill
0
Comment
Question by:bjennings
3 Comments
 
LVL 17

Accepted Solution

by:
MIKE earned 400 total points
ID: 24062341
Try this:

if (({#LYSales} + ({#LYSales} * {@goalpercent}))) <0
  then ({#LYSales} + ({#LYSales} * {@goalpercent})) *-1
    else ({#LYSales} + ({#LYSales} * {@goalpercent}))
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 24062426
How do you know it isn't calculating correctly?

mlmcc
0
 

Author Closing Comment

by:bjennings
ID: 31566360
Pefect!  Thanks!
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

761 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