Excel formula for retrieving last portion of a url
I am trying to write a excel forumla that takes the following:
http://www.saga.co.uk/money/taxandbenefits/carersallowance.asp
http://www.saga.co.uk/money/taxandbenefi开发者_运维问答ts/index.asp
and from these 2 examples would output:
carersallowance
index
Anyone know how this could be done ? Help would be most appreciated.
If you example was in A1 try
=SUBSTITUTE(REPLACE(A1,1,LOOKUP(2^15,FIND("/",A1,ROW(INDIRECT("1:"&LEN(A1))))),""),".asp","")
Another way;
=RIGHT(A1,LEN(A1)-FIND("::",SUBSTITUTE(A1,"/","::",LEN(A1)-LEN(SUBSTITUTE(A1,"/","")))))
精彩评论