ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Charts and Charting in Excel (https://www.excelbanter.com/charts-charting-excel/)
-   -   Formula help (https://www.excelbanter.com/charts-charting-excel/223835-formula-help.html)

Steph

Formula help
 
I have data that looks like this:

S30 1M D C7D
S30 1M D
5W I 4
2W I X AH1

I need a formula that will extract the third group of characters from each
record. The records can be any length and the groups are seperated by
spaces. For example,

From "S30 1M D C7D" I need to extract "D".
From "S30 1M D" I need to extract "D".
From "5W I 4" I need to extract "4".
From "2W I X AH1" I need to extract "X".

Thanks for any help that can be provided.

--
Steph

Steph

Formula help
 
I apologize. I accidently posted to the wrong group.

--
Steph


"Steph" wrote:

I have data that looks like this:

S30 1M D C7D
S30 1M D
5W I 4
2W I X AH1

I need a formula that will extract the third group of characters from each
record. The records can be any length and the groups are seperated by
spaces. For example,

From "S30 1M D C7D" I need to extract "D".
From "S30 1M D" I need to extract "D".
From "5W I 4" I need to extract "4".
From "2W I X AH1" I need to extract "X".

Thanks for any help that can be provided.

--
Steph


PBezucha

Formula help
 
Steph,

Still, most simple solution by a UDF:

Function S(Arg As String) As String
S = Split(Arg, " ")(2)
End Function
--
Regards

Petr Bezucha


"Steph" wrote:

I apologize. I accidently posted to the wrong group.

--
Steph


"Steph" wrote:

I have data that looks like this:

S30 1M D C7D
S30 1M D
5W I 4
2W I X AH1

I need a formula that will extract the third group of characters from each
record. The records can be any length and the groups are seperated by
spaces. For example,

From "S30 1M D C7D" I need to extract "D".
From "S30 1M D" I need to extract "D".
From "5W I 4" I need to extract "4".
From "2W I X AH1" I need to extract "X".

Thanks for any help that can be provided.

--
Steph


Shane Devenshire

Formula help
 
Hi,

No need for a UDF here is a simple formula

=MID(A1,FIND(" ",A1,FIND(" ",A1)+1)+1,20)

Or you chan choose Data, Text to Columns, Delimited, click Next choose
Space, click Next, select the first two columns in the Data Preview pane and
choose Do not import (Skip), set a destination...

--
If this helps, please click the Yes button.

Cheers,
Shane Devenshire


"Steph" wrote:

I have data that looks like this:

S30 1M D C7D
S30 1M D
5W I 4
2W I X AH1

I need a formula that will extract the third group of characters from each
record. The records can be any length and the groups are seperated by
spaces. For example,

From "S30 1M D C7D" I need to extract "D".
From "S30 1M D" I need to extract "D".
From "5W I 4" I need to extract "4".
From "2W I X AH1" I need to extract "X".

Thanks for any help that can be provided.

--
Steph



All times are GMT +1. The time now is 07:16 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com