Combine 3 columns and rename cells with 0 value

polks111

New Member
Joined
Jun 14, 2021
Messages
2
Office Version
  1. 365
Platform
  1. Windows
Hello,

I have been struggling with this task for a while and thought maybe someone can help me here.
I need to combine data from 3 columns and when combined all cell text where the value is 0 needs to be replaced with words Not affected. Can`t find any suitable formula or VBA code for this.

Data.xlsx
ABCDE
1ResultPayoutCurrencyAll 3 combined with formulaNeeded result
2Overpaid34.5MYROverpaid 34.5 MYROverpaid 34.5 MYR
3Overpaid0EUROverpaid 0 EURNot affected
4Overpaid0USDOverpaid 0 USDNot affected
5Overpaid0MXNOverpaid 0 MXNNot affected
6Overpaid0BRLOverpaid 0 BRLNot affected
7Overpaid5BRLOverpaid 5 BRLOverpaid 5 BRL
8Refund45000COPRefund 45000 COPRefund 45000 COP
9Overpaid0.5JPYOverpaid 0.5 JPYOverpaid 0.5 JPY
10Overpaid0MYROverpaid 0 MYRNot affected
11Overpaid4CADOverpaid 4 CADOverpaid 4 CAD
12Overpaid0GBPOverpaid 0 GBPNot affected
13Refund60MXNRefund 60 MXNRefund 60 MXN
14Refund135MYRRefund 135 MYRRefund 135 MYR
15Refund108GBPRefund 108 GBPRefund 108 GBP
16Refund6000INRRefund 6000 INRRefund 6000 INR
17Refund0.2MXNRefund 0.2 MXNRefund 0.2 MXN
Data
Cell Formulas
RangeFormula
D2:D17D2=A2&" " &B2& " " &C2
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Hi & welcome to MrExcel.
How about
Excel Formula:
=IF(B2=0,"No affected",TEXTJOIN(" ",,A2:C2))
 
Upvote 0
Solution
Welcome to the MrExcel Message Board!

Cross-posting (posting the same question in more than one forum) is not against our rules, but the method of doing so is covered by #13 of the Forum Rules.

Be sure to follow & read the link at the end of the rule too!

Cross posted at: Combine 3 columns and rename cells with 0 value
If you have posted the question at more places, please provide links to those as well.

If you do cross-post in the future and also provide links, then there shouldn’t be a problem.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,324
Members
452,635
Latest member
laura12345

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