Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 73
Default Reading the characters in a cell

I have the name of a fund in the cell...for example:

American Century LIVESTRONG 2045 R
Fidelity Advisor Freedom 2035 A
Fidelity Advisor Freedom 2035 I
Fidelity Advisor Freedom 2040 I
Fidelity Freedom 2035
Fidelity Freedom 2040
Principal LifeTime 2030 Inst
Principal LifeTime 2030 R4

I need the date copies to another column
and i need all of the letters after the date copied into another column as
well

i have a list of over 600 lines...

any ideas?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,101
Default Reading the characters in a cell

I don't see a date in your examples

"dstiefe" wrote:

I have the name of a fund in the cell...for example:

American Century LIVESTRONG 2045 R
Fidelity Advisor Freedom 2035 A
Fidelity Advisor Freedom 2035 I
Fidelity Advisor Freedom 2040 I
Fidelity Freedom 2035
Fidelity Freedom 2040
Principal LifeTime 2030 Inst
Principal LifeTime 2030 R4

I need the date copies to another column
and i need all of the letters after the date copied into another column as
well

i have a list of over 600 lines...

any ideas?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Reading the characters in a cell

Select the cells you want to parse and run:

Sub dateSpliter()
For Each r In Selection
s = Split(r.Value, " ")
For i = 0 To UBound(s)
If IsNumeric(s(i)) Then
r.Offset(0, 1).Value = s(i)
If i < UBound(s) Then
r.Offset(0, 2).Value = s(i + 1)
End If
End If
Next
Next
End Sub
--
Gary''s Student - gsnu200814


"dstiefe" wrote:

I have the name of a fund in the cell...for example:

American Century LIVESTRONG 2045 R
Fidelity Advisor Freedom 2035 A
Fidelity Advisor Freedom 2035 I
Fidelity Advisor Freedom 2040 I
Fidelity Freedom 2035
Fidelity Freedom 2040
Principal LifeTime 2030 Inst
Principal LifeTime 2030 R4

I need the date copies to another column
and i need all of the letters after the date copied into another column as
well

i have a list of over 600 lines...

any ideas?

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
convert 5 characters in a cell to 6 characters by adding a zero Helenf Excel Discussion (Misc queries) 4 May 18th 09 04:43 PM
Excel OLEDB reading Chinese characters problem [email protected] Excel Programming 0 September 12th 06 04:42 AM
Reading a cell in VBA Ruatha New Users to Excel 3 June 11th 06 04:01 PM
Reading last cell jackh7777777 Excel Discussion (Misc queries) 2 May 26th 06 01:28 AM
Cell Reading Problem Shashi Bhosale Excel Programming 2 July 22nd 04 01:37 PM


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

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

About Us

"It's about Microsoft Excel"