Trim/Substitute but.. also, replace?

srosk

Board Regular
Joined
Sep 17, 2018
Messages
132
Situation is, I am using the following code to get some pretty specific text over from column A to column C.

Code:
=TRIM(SUBSTITUTE(A57,B57,""))

The first 2 words are always equal to Network Bridge, followed by other text.

My question is, is there a way to eliminate the space between the words network bridge within this formula without spreading over to another column?​ I know I can use the replace function, but then I'd have to spread over to column D which would not be desirable. Thank you kindly for all of your help!
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
Can you provide a couple of examples of the before and after (desired) result?

Matty
 
Upvote 0
For instance, the output of the trim/substitute formula shown above is:

Network Bridge 4.19 2.54 4.19 -1.48 6.83 4.58 8.39 8.42

I would like the output to be:

NetworkBridge 4.19 2.54 4.19 -1.48 6.83 4.58 8.39 8.42

But, would somehow, like this code to accompany:

Code:
[COLOR=#333333]=TRIM(SUBSTITUTE(A57,B57,""))[/COLOR]

 
Upvote 0
Unless I'm missing something, isn't this just:

Code:
=SUBSTITUTE(A1,"Network Bridge","NetworkBridge")
Matty
 
Upvote 0
Hi,

Use this:

=SUBSTITUTE(TRIM(SUBSTITUTE(A57,B57,""))," ","",1)
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,238
Messages
6,170,939
Members
452,368
Latest member
jayp2104

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top