View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Rick Rothstein Rick Rothstein is offline
external usenet poster
 
Posts: 5,934
Default Parsing Question

Use this formula for retrieving the contents of the first bracket...

=TRIM(RIGHT(SUBSTITUTE(LEFT(A1,FIND("]",A1)-1),"[",REPT(" ",99)),99))


Actually, you can use this shorter and more efficient formula to do the same
thing...

=MID(LEFT(A1,FIND("]",A1)-1),FIND("[",A1)+1,5)

Rick Rothstein (MVP - Excel)