show value of formula

  • Thread starter Thread starter geebee
  • Start date Start date
G

geebee

hi,

i am trying to figure out how i can have in my VBA to show the value of:
=MID(RIGHT(A1,5),2,3)

where A1 is the cell in the active sheet.

thanks in advance,
geebee
 
Msgbox MID$(Range("A1").Value,LEN(Range("A1").Value)-3,3)

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
Try...

MsgBox Mid(Right(ActiveSheet.Range("A1"), 5), 2, 3)

Rick
 
Hi, it will look like this in VBA code:

Range("A6").Select
ActiveCell.FormulaR1C1 = "=MID(RIGHT(R[-5]C,5),2,3)"

It will put
=MID(RIGHT(A1,5),2,3)
to cell A6

I figured it out with the macro recording function.

I hope this is what you've asked for, if not be more specific please.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

format number 2
format 5
sum in range meeting criteria 3
pivot table showing text 3
proper 4
Extract time from date 4
range values 1
autofilter criteria 3

Back
Top