View Single Post
  #14   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bradley Bradley is offline
external usenet poster
 
Posts: 16
Default Pls help me to solve this problem...

Thanks, Harlan Grove.
Your formula is simple and short.
But when i copy your formula and paste there, it's an error that showing ("").
So i added some brackets and it's ok..
=IF(LEN(A1)6,MID(A1,LEN(A1)-6,1),"") --
=IF(LEN(A1)6,(MID(A1,LEN(A1)-6,1)),"")

Tom

"Harlan Grove" wrote:

JLatham <HelpFrom @ Jlathamsite.com.(removethis) wrote...
Try these

in A2
=IF(ISERR(MID(A1,LEN(A1)-6,1)),"",MID(A1,LEN(A1)-6,1))

....

If you're going to do this much hardcoding, might as well simplify.

=IF(LEN(A1)6,MID(A1,LEN(A1)-6,1),"")

and similarly for B2:G2.

MID would only return an error in the formula above when either A1
evaluated to an error or its 2nd argument wasn't a positive number.
Best to let errors in A1 propagate and only test the length of A1.