Condensing text values from one wksht to another

J

jayceejay

I have text data in column A of sheet one that is too lengthy. I wish to condense the data by copying JUST that data that leads up to the first space (break in the string)and copy to column A of sheet two. Example: blah,blah,blah blahhhh becomes blah,blah,blah. Is there a formula for the destination cell in sheet two that will accomplish this task, or does it require vba? If so, could someone walk me through it?? I am nearing desperation. Please help!!!!
 
A

A.W.J. Ales

Jayceejay,

In cell A1 of sheet2 fill in this formula and copy it down to A??

=LEFT(Sheet1!A1,FIND(" ",Sheet1!A1,1)-1)

I assume that your data in sheet1 is in A1:A??

--
Regards,
Auk Ales

* Please reply to this newsgroup only *
* I will not react on unsolicited e-mails *

jayceejay said:
I have text data in column A of sheet one that is too lengthy. I wish to
condense the data by copying JUST that data that leads up to the first space
(break in the string)and copy to column A of sheet two. Example:
blah,blah,blah blahhhh becomes blah,blah,blah. Is there a formula for the
destination cell in sheet two that will accomplish this task, or does it
require vba? If so, could someone walk me through it?? I am nearing
desperation. Please help!!!!
 
J

JE McGimpsey

one way:

In sheet2, A1:

=IF(ISERR(FIND(" ",Sheet1!A1)),Sheet1!A1,LEFT(Sheet1!A1,FIND(" ",
Sheet1!A1)-1))
 
A

A.W.J. Ales

Jayceejay,

This is the better one. I overlooked the possibility that the string in A1
doesn't contain (a) space(s).

Thanks JE.

--
Regards,
Auk Ales

* Please reply to this newsgroup only *
* I will not react on unsolicited e-mails *
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top