Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
BigIan
 
Posts: n/a
Default Subtract text in one cell from another?

Hi,

I would like to subtract text in one cell from another, can anybody tell me
if it can be done?

For example:
Cell A1 has "John Smith"
Cell B1 has "John Smith violin teacher"

Can I subtract cell A1's contents from cell B1's contents to leave "violin
teacher"?
  #2   Report Post  
bj
 
Posts: n/a
Default

in C1 enter
=substitute(B1,A1,"")

"BigIan" wrote:

Hi,

I would like to subtract text in one cell from another, can anybody tell me
if it can be done?

For example:
Cell A1 has "John Smith"
Cell B1 has "John Smith violin teacher"

Can I subtract cell A1's contents from cell B1's contents to leave "violin
teacher"?

  #3   Report Post  
Dave Peterson
 
Posts: n/a
Default

I'd add...

=trim(substitute(B1,A1,""))

to get rid of the space between smith and violin.

Or maybe even...

=substitute(B1,A1&" ","")

bj wrote:

in C1 enter
=substitute(B1,A1,"")

"BigIan" wrote:

Hi,

I would like to subtract text in one cell from another, can anybody tell me
if it can be done?

For example:
Cell A1 has "John Smith"
Cell B1 has "John Smith violin teacher"

Can I subtract cell A1's contents from cell B1's contents to leave "violin
teacher"?


--

Dave Peterson
  #4   Report Post  
BigIan
 
Posts: n/a
Default



"Dave Peterson" wrote:

I'd add...

=trim(substitute(B1,A1,""))

to get rid of the space between smith and violin.

Or maybe even...

=substitute(B1,A1&" ","")

bj wrote:

in C1 enter
=substitute(B1,A1,"")

"BigIan" wrote:

Hi,

I would like to subtract text in one cell from another, can anybody tell me
if it can be done?

For example:
Cell A1 has "John Smith"
Cell B1 has "John Smith violin teacher"

Can I subtract cell A1's contents from cell B1's contents to leave "violin
teacher"?


--

Dave Peterson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Possible Lookup Table Karen Excel Worksheet Functions 5 June 8th 05 09:43 PM
Cell set to wrap text and blank line -- fix? Fred Holmes Excel Discussion (Misc queries) 0 January 25th 05 07:10 PM
Moving text from one cell to another. estaban botas Excel Worksheet Functions 1 December 15th 04 02:04 PM
Formatting a cell as "text" in the number catagory. Ed Excel Worksheet Functions 3 December 7th 04 07:12 PM
Forcing text onto new line in cell Doug Poll New Users to Excel 2 December 3rd 04 12:09 PM


All times are GMT +1. The time now is 04:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"