Thread: Mid,Find,Len
View Single Post
  #1   Report Post  
Rachel
 
Posts: n/a
Default Mid,Find,Len

Hi
A1= abcd_XXXXXyyyyyyy_AB
B1 = yyyyyyy
I am trying to extract the XXXXX portion of A1 with this formula....

C1=MID(A1,FIND("_",A1)+1,FIND("_",A1,FIND("_",A1)+ 1)-FIND("_",A1)-1-LEN(B1))

Which works fine for this example however if len(b1) changes then the result
changes in the same manner. What am I doing worng?
Thanks