View Single Post
  #16   Report Post  
Posted to microsoft.public.excel.worksheet.functions
janabanana janabanana is offline
external usenet poster
 
Posts: 12
Default Need a formula to give me the last value in a column.

ok, Mr. Formula Man, here is another one for you:
i hope i can describe it well enough for you.
formula history:
sheet = LOG
sheet = PRINT
In the LOG sheet, i have a column (X) that contains a formula where if i
type in a number in another column(Y), it returns a name that equals that
number (displays an operator's name instead of the operator's number).
then in the PRINT sheet, i have a formula that looks back at the LOG sheet,
finds the last non-blank cell in column X, and displays it's value in
PRINT!E51
Problem:
if i type in a number in LOG!columnY, sometimes that number does not have a
name associated with it. in that case, it returns #n/a, i have a conditional
format in this column that says if the return is an error (#n/a) then hide it
(font=white).
but, back in the PRINT sheet, it is still returning the last non-blank cell.
What i need it to return in PRINT! is a blank cell since it couldn't find a
name to match the number.what i want it to do is look at the first non-blank
ROW in the LOG,
formula in PRINT sheet something like this: Destination cell (PRINT!E51) go
to the last non-blank row in LOG!columnA, if it is non-blank, then use the
value in LOG column X, no matter what it is, not necessarily the last
non-blank in column X.

if you are still confused about what i want, i could maybe try sending you
the workbook
--
jana


"T. Valko" wrote:

You're welcome. Thanks for the feedback!

--
Biff
Microsoft Excel MVP


"janabanana" wrote in message
...
Worked wonderfully.
Thank you so much.
--
jana


"T. Valko" wrote:

Try this:

Goto the menu InsertNameDefine
Name: LastCell
Refers to:

=INDIRECT("Log!K"&LOOKUP(2,1/(Log!$K$1:$K$1000<0),ROW(Log!$K$1:$K$1000)))

OK

Click within the textbox to make it active
Enter this formula in the formula bar: =LastCell
Hit ENTER


--
Biff
Microsoft Excel MVP


"janabanana" wrote in message
...
The formula that has worked so far (when typing it in a cell) is:
=LOOKUP(2,1/(LOG!K1:K1000<0),LOG!K1:K1000).

Now I have a text box that I would like to type this formula in (using
the
formula bar after I select the correct box) and it doesn't seem to want
to
go.
--
jana


"T. Valko" wrote:

Where do we look for the the last text entry?

Here's what you need to do:

Get the address of the cell in question.

Wrap that inside an INDIRECT function.

Give the INDIRECT function a defined name.

Then, as the source for the textbox use =defined_name

--
Biff
Microsoft Excel MVP


"janabanana" wrote in message
...
i know this was a few months back, but i have tried using all of
these
formulas and cannot get one to work with a text box.
i have a text box in a worksheet. if i simply type: =LOG!A1 then it
displays
the text in A1 of my Log sheet.
however, i need it to display the text in the last cell with text in
that
sheet.
i have typed in all of your options and keep getting a "The text you
entered
is not a valid reference or defined name."

Thoughts?
--
jana


"Ron Coderre" wrote:

Try one of these:

The VALUE of the last NUMERIC value in Col_A:
=LOOKUP(10^99,A:A)

The VALUE of the last TEXT cell in Col_A
=LOOKUP(REPT("z",255),A:A)

The VALUE of the last NON-BLANK, NON-ZERO cell in a COLUMN range
=LOOKUP(2,1/(A1:A100<0),A1:A100)

The VALUE of the last NON-BLANK cell in a COLUMN range
=LOOKUP(2,1/(A1:A100<""),A1:A100)

Is that something you can work with?
--------------------------

Regards,

Ron
Microsoft MVP (Excel)
(XL2003, Win XP)

"SMH" wrote in message
...
Within one workbook, I'm trying to have one tab read off another
using
a
formula. I need the "Summary" tab to display the last cell with
data
(not
null) in a particular column. For example, column A has data
populated
from
A2:A50, I want to show A50. Any suggestions?