Solved

Prices / currency calculation in a view

Posted on 2004-08-09
2
280 Views
Last Modified: 2013-12-18
I would like to do the following in a view formula: have it display a price (which is entered on the document by the user), calculate the tax (7% Canadian GST), and add it to the price for a total.

i.e. to have the view column formulate something like the following: $1,295.00 + $90.65 = $1,385.65 (if the "price" field contains $1,295.00)

The problem I am having is that the view column converts the currency amount to a plain number (i.e. $1,295.00 to 1295), but when I configure the column for currency it will not accept the any text strings (" + ", " = ", etc.).

Is there any way to get the view column to calculate and display like this -- $1,295.00 + $90.65 = $1,385.65 ?

-Ke
0
Comment
Question by:kkiddie
2 Comments
 
LVL 15

Accepted Solution

by:
Bozzie4 earned 200 total points
ID: 11759742
You can, using a string (you'll need to adapt the rounding rules to what applies in Canada) :

price := mypricefield;
tax := price*7/100;
total := @round(price + tax;1/100);
@text( price; "C,2")+ " + " + @text( tax; "C,2") + " = " + @text( total; "C,2")

But you will probably want these values in your documents too, so it's better to do these calculations in fields in your documents !

cheers,

Tom

0
 

Author Comment

by:kkiddie
ID: 11761967
Thanks, Tom. It works.

I should have read more of the @Text help, I guess the answer was there... Still it is helpful for me as a beginning coder to see your approach.

Cheers,

-Kendall
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

For Desktop Techs: How to retain a user's Notes configuration data when swapping out the end user's computer. (Assuming that you are not upgrading to a completely different version of Notes client) All you need to do is: 1) install Notes o…
Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

864 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

19 Experts available now in Live!

Get 1:1 Help Now