问题
How do you remove a particular word in a column of one cell that's in another cell in Excel.
Example: if
- A1 =
*1603 Ad street New York*
, - B1 =
*New York*
- then in C1 I want =
*1603 Ad street*
回答1:
Use the Substitute function:
=SUBSTITUTE(A1,B1,"")
EDIT: Per brettdj's suggestion, added TRIM to get rid of leading or trailing spaces:
=TRIM(SUBSTITUTE(A1,B1,""))
回答2:
Just use the Replace function. leave " replace with" blank
回答3:
Try this formula for range of words:
=TRIM(SUBSTITUTE(A1,INDEX($B$1:$B$56,IF(ISNA(MATCH(FALSE,ISERR(FIND($B$1:$B$56,A1)),FALSE)),0,MATCH(FALSE,ISERR(FIND($B$1:$B$56,A1)),FALSE)),1),""))
来源:https://stackoverflow.com/questions/6209509/how-to-remove-a-particular-word-in-an-excel-cell