John Fletcher
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
In an excel workbook the download from our financial package has the Project Ref No AND the Project Description in column A.
I need to have a list of Project Numbers WITHOUT the Project Description in the same cell. Is there a macro or shortcut where I can 'extract' the first 5 characters from the text string and copy them to another set of cells in an adjacent blank column? The original cells do not need to have the Project Ref No removed from column A.
Thank you.
John Fletcher
Chris Burrage
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
Hi John
The LEFT or RIGHT function will do the job. For example if cell A1 contains AAA123, and you enter =LEFT(A1,3) in the next cell over (or anywhere else for that matter) the result will be AAA, as the function extracts the leftmost three characters from cell A1.
Enjoy
Chris B
Stephen Byrne
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
Use the following formula in the adjacent cells.
=LEFT(A1,5)
Pete Cuthbert
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
Assuming the data you want to split is in D2
in E2 enter the formula =(LEFT(D2,FIND(" ",D2)-1) which will find all the data to the first space. If there is a different delimiter put it between the quotes.
Good luck
Pete
A Davies
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
Hello John
I would probably try to use the MID command.
eg if A1 contains PROJ1 - Project particulars
then type in the cell that you want the project number to be in (B1)
=mid(a1,1,5)
This will return the string "PROJ1"
I hope this is of assistance.
Anonymous
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
The formula is "=LEFT(A3,5)" if A3 is the cell with the Project Nos (no quotes)
Imi
Lorenzo Marasco
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
You can use either of the following commands.
=left(cell,number of characters)
=right(cell,number of characters)
=mid(cell,starting point, number_of_characters_to_copy)
If A1 = "ABCDEFG"
then =Left(A1, 2) will result in "AB"
then =Right(A1, 2) will result in "FG"
then =Mid(A1, 2,3) will result in "BCD"
John Fletcher
Posted 8 years, 4 months ago
Joined: 12 years, 5 months ago
Re: Excdel - Copy part of a text string from a cell
Thanks - your suggestions have worked 100%
theamyday
Posted 11 months, 2 weeks ago
Joined: N/A
Time Released Caffene Pills http://www.strapdoctor.com/ - accutane for acne Thank God there is a great drug like Accutane. http://www.strapdoctor.com/ - generic accutane without prescription