Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Cell wording should change if result is +ve or -ve


I have a calculation with one cell containing the result. The wording
next to the cell should read

"Jane owes Peter:" if the result of the calculation is positive
and
"Peter owes Jane:" if the result is negative but it should show the
absolute value.

I am grateful for any help


--
karambos
------------------------------------------------------------------------
karambos's Profile: http://www.excelforum.com/member.php...o&userid=16262
View this thread: http://www.excelforum.com/showthread...hreadid=541726

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Cell wording should change if result is +ve or -ve

=if(a1=b1,"No debt",if(a1<b1,"Jane owes Peter: ","Peter owes Jane: "))
& text(abs(a1-b1),"$0.00")

You can use the text() worksheet function to give the difference a nice format.

=if(a1=b1,"No debt",if(a1<b1,"Jane owes Peter: ","Peter owes Jane: "))
& text(abs(a1-b1),"$0.00") & " due on: " & text(c1,"mm/dd/yyyy")

(if you had the date in C1)

karambos wrote:

I have a calculation with one cell containing the result. The wording
next to the cell should read

"Jane owes Peter:" if the result of the calculation is positive
and
"Peter owes Jane:" if the result is negative but it should show the
absolute value.

I am grateful for any help

--
karambos
------------------------------------------------------------------------
karambos's Profile: http://www.excelforum.com/member.php...o&userid=16262
View this thread: http://www.excelforum.com/showthread...hreadid=541726


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I copy the wording of a cell into a tab? Jamie Excel Discussion (Misc queries) 2 January 24th 10 07:48 PM
No change in result cell jiang Excel Worksheet Functions 1 September 20th 06 06:20 PM
Result of IF conditional change cell color Olasin Excel Discussion (Misc queries) 1 May 16th 06 10:37 PM
How do I change the color of a cell depending on the result of the function in that cell Mo Childs[_2_] Excel Programming 4 November 1st 05 09:30 PM
Change the color of a cell change dependant on a result KFEagle Excel Programming 2 April 4th 05 02:20 PM


All times are GMT +1. The time now is 04:14 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"