Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 505
Default Excel 2002: How to extract characters ?

Dear Sir,

I wish to extract the last 6 characters if a cell in column A has 13
characters, otherwise only extract the last 3 characters.

Illustration:

A B
1 510104BGH9006 BGH9006
2 510104TRL TRL
3 510104OTH9016 OTH9016
4 510202HLG HLG
5 510104KJY9018 KJY9018
6 510203FTP FTP
7 510104IPL9023 IPL9023
8 510209SGS SGS

May I know what formula must input at cell B1 and copy downwards to get the
answer ?

Thanks

Low



--
A36B58K641
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default Excel 2002: How to extract characters ?

B1 contents is
=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))

Mr. Low wrote:

Dear Sir,

I wish to extract the last 6 characters if a cell in column A has 13
characters, otherwise only extract the last 3 characters.

Illustration:

A B
1 510104BGH9006 BGH9006
2 510104TRL TRL
3 510104OTH9016 OTH9016
4 510202HLG HLG
5 510104KJY9018 KJY9018
6 510203FTP FTP
7 510104IPL9023 IPL9023
8 510209SGS SGS

May I know what formula must input at cell B1 and copy downwards to get the
answer ?

Thanks

Low




  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default Excel 2002: How to extract characters ?

Hi,

I've assumed you mean = 13 but if I'm incorrect in that assumption use the
second version. the formula can be dragged

=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))
=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))

Mike

"Mr. Low" wrote:

Dear Sir,

I wish to extract the last 6 characters if a cell in column A has 13
characters, otherwise only extract the last 3 characters.

Illustration:

A B
1 510104BGH9006 BGH9006
2 510104TRL TRL
3 510104OTH9016 OTH9016
4 510202HLG HLG
5 510104KJY9018 KJY9018
6 510203FTP FTP
7 510104IPL9023 IPL9023
8 510209SGS SGS

May I know what formula must input at cell B1 and copy downwards to get the
answer ?

Thanks

Low



--
A36B58K641

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 505
Default Excel 2002: How to extract characters ?

Hello Bob,

Thanks for the formula.

Low
--
A36B58K641


"Bob I" wrote:

B1 contents is
=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))

Mr. Low wrote:

Dear Sir,

I wish to extract the last 6 characters if a cell in column A has 13
characters, otherwise only extract the last 3 characters.

Illustration:

A B
1 510104BGH9006 BGH9006
2 510104TRL TRL
3 510104OTH9016 OTH9016
4 510202HLG HLG
5 510104KJY9018 KJY9018
6 510203FTP FTP
7 510104IPL9023 IPL9023
8 510209SGS SGS

May I know what formula must input at cell B1 and copy downwards to get the
answer ?

Thanks

Low





  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 505
Default Excel 2002: How to extract characters ?

Hello Mike,

Thanks for the formula.

I need the second one.

Kind Regards

Low

--
A36B58K641


"Mike H" wrote:

Hi,

I've assumed you mean = 13 but if I'm incorrect in that assumption use the
second version. the formula can be dragged

=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))
=IF(LEN(A1)=13,RIGHT(A1,6),RIGHT(A1,3))

Mike

"Mr. Low" wrote:

Dear Sir,

I wish to extract the last 6 characters if a cell in column A has 13
characters, otherwise only extract the last 3 characters.

Illustration:

A B
1 510104BGH9006 BGH9006
2 510104TRL TRL
3 510104OTH9016 OTH9016
4 510202HLG HLG
5 510104KJY9018 KJY9018
6 510203FTP FTP
7 510104IPL9023 IPL9023
8 510209SGS SGS

May I know what formula must input at cell B1 and copy downwards to get the
answer ?

Thanks

Low



--
A36B58K641



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default Excel 2002: How to extract characters ?

You're welcome, have a great day.

Mr. Low wrote:
Hello Bob,

Thanks for the formula.

Low


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2002 : How to extract data from columns ? Mr. Low Excel Discussion (Misc queries) 2 September 14th 07 04:56 PM
How can I enter spanish accented characters into excel 2002? Richleemcc Excel Discussion (Misc queries) 2 June 28th 07 03:53 PM
Excel 2002: Single step of selecting characters Mr. Low Excel Discussion (Misc queries) 5 May 4th 07 05:12 PM
Excel 2002 : How to extract references from a list ? Mr. Low Excel Discussion (Misc queries) 6 December 2nd 06 10:48 PM
HOW DO I EXTRACT ALL CHARACTERS AFTER 5 CHARACTERS ON LEFT GRYSYF Excel Worksheet Functions 5 October 12th 05 10:58 AM


All times are GMT +1. The time now is 02:42 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"