简体   繁体   中英

Excel: string split

Can anyone tell me the formula to split the a8399em,a1445f01m,h60853w....from the strings

I have this kind of strings:

.../images/options/kiss-off-t-shirt_red_men_tshirts_a8399em.jpg

.../images/options/ask-me-if-i-care--t-shirt_black_men_tshirts_a1445f01m.jpg

.../images/options/thumbs/dont-marry-by-happy-women-t-shirt_blue_women_tshirts_thumb_h60853w.jpg

I need to split this a8399em from the string

As you can see before the number that i need, there is a "_" and after the number there is a "."

Thanks

With your string in A1 , in B1 enter:

=SUBSTITUTE(MID(A1,FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1),LEN(A1)-LEN(SUBSTITUTE(A1," ",""))))+1,255),".jpg","") and copy down

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM