Format cell?

S

Sophie

How do I format a cell to read the following.

56033
or
56034/34

I input the data above on cell"A1" and on cell "F1" I have the following
formula =A1
It works with the first number but not with the second one.
Any ideas?
 
J

John

Hi Sophie
You say its not working, what is it doing? what are you getting in that cell?
John
 
S

Sophie

In cell "A1" has the following formular
=LOOKUP(2,1/(detail!D4:D4997),detail!D4:D4997)
which looks up the column and picks the last entry. But if the number has a
forward slash it picks the next number with no slash.
Cell "F1" displays what is in cell "A1".
 
D

Dave Peterson

Actually, that formula picks up the last numeric (non-zero) entry.

If you want the last non-empty entry:
=LOOKUP(2,1/(detail!D4:D4997<>""),detail!D4:D4997)
 
Top