title: Excel: extract only substrings beginning with a certain character
body: <p>I have a column of cells containing a variable amount of text up to 140 characters in length. What I would like to do is write a function that will parse these strings for only words beginning with "@" and organize them in a single adjacent cell separated by spaces.</p>
  
  <p>These substrings vary in length and in their position within the string. And there might be more than one substring beginning with "@" in the cell to pull.</p>
  
  <p>I have tried it in many different ways which have been unsuccessful. Thanks in advance for your advice!</p>
  
  <p>Here is a way that seems to work, but is probably not the "correct" way:</p>
  
  <p>The objective was to parse column C, containing tweets, for all the "mentions" (strings beginning with @) and put them in an adjacent cell in column D. </p>
  
  <p>I took all the content from column C and pasted it into a new sheet. Then I did text-to-column so that the tweet was put into cells word by word. On these cells I used the function (dragged out) =IF(ISNUMBER(FIND("@",B3)),CONCATENATE(B3," "),"") in order to separate the twitter handles only into columns below. I think there needs to be a space added in case there are multiple handles to join.</p>
  
  <p>Then I used another nested CONCATENATE function =CONCATENATE(IF(B34="","",B34),IF(B35="","",B35)...,IF(B65="","",B65) to put the handles, now followed by spaces, together in a single cell. It had to be written this way as a workaround for the #VALUE error for the CONCATENATE function in blank cells.</p>
  
  <p>Then I selected the whole row, copied and transposed it into a column. Then selected the column, pasted values only into my original sheet in column D. The handles all line up with the corresponding tweet.</p>
  
  <p>I would love to learn how to do this in the proper way.</p>