ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Second last number in list (https://www.excelbanter.com/excel-worksheet-functions/111102-second-last-number-list.html)

TeddyTash

Second last number in list
 
Steve asked previously

How to find the last number on a list that varies in size:

The solution he was given was =LOOKUP(99^99,A:A)
Which works perfectly.


Now.... is it possible to find the second last number?


Thanks in advance,
Teddy

Ron Coderre

Displaying all numbers as positive
 
Try using a custom number format:

Select the cells to be impacted.
From the Excel main menu:
<format<cells<number tab
Category: Custom
Type: #,##0;#,##0;#,##0

Note that format contains 3 sections: postive display, negative display,
zero display
Experiment with other options if you need to.

Also, look up "number format" in Excel help for other options.

Does that help?
***********
Regards,
Ron

XL2002, WinXP


"TeddyTash" wrote:


Ok hope you guys can help:

A1= x
A2= y
A3= A1-A2

If the answer is a positive number I want it to remain as a positive
number
-but-
If the answer is a negative number, I wish for it to be displayed
without the "-" sign before the number so it looks like it's a positive
number. But I also want it to hold it's negative value so that it can be
used later on.

Example:
A1= 5
A2= 8
A3= A1-A2

A3 Normally displays "-3", I want it to display "3".

But I also need it so that if I make A4=A3, then A4 will display "-3"

Hope this makes sense to someone!


Thanks in advance,
Teddy




--
TeddyTash


TeddyTash

Thank you Ron,



Quote:

Originally Posted by Ron Coderre
Try using a custom number format:

Select the cells to be impacted.
From the Excel main menu:
formatcellsnumber tab
Category: Custom
Type: #,##0;#,##0;#,##0

Note that format contains 3 sections: postive display, negative display,
zero display
Experiment with other options if you need to.

Also, look up "number format" in Excel help for other options.

Does that help?
***********
Regards,
Ron

XL2002, WinXP


"TeddyTash" wrote:


Ok hope you guys can help:

A1= x
A2= y
A3= A1-A2

If the answer is a positive number I want it to remain as a positive
number
-but-
If the answer is a negative number, I wish for it to be displayed
without the "-" sign before the number so it looks like it's a positive
number. But I also want it to hold it's negative value so that it can be
used later on.

Example:
A1= 5
A2= 8
A3= A1-A2

A3 Normally displays "-3", I want it to display "3".

But I also need it so that if I make A4=A3, then A4 will display "-3"

Hope this makes sense to someone!


Thanks in advance,
Teddy




--
TeddyTash



All times are GMT +1. The time now is 06:38 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com