Populating column

montanaaggie

Board Regular
Joined
Nov 11, 2005
Messages
118
Office Version
  1. 365
Platform
  1. Windows
I have three columns, A,B,C. Column A is prefilled data. Column B is data I may or may not enter. Could some please provide the if statement exactly as needed to populate Column C on the following conditions. If Column B has numbers populate Column C with them. If no numbers are in Column B, use numbers in Column A.

Thanks for the help.
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

HalfAce

MrExcel MVP
Joined
Apr 6, 2003
Messages
9,456
montanaaggie said:
I have three columns, A,B,C. Column A is prefilled data. Column B is data I may or may not enter. Could some please provide the if statement exactly as needed to populate Column C on the following conditions. If Column B has numbers populate Column C with them. If no numbers are in Column B, use numbers in Column A.

Thanks for the help.
Hello. Welcome to the board.
If all you're dealing with is numeric values then this (in C1 & copied down) should work.
It simply checks to see if B1 is blank.
If it is, it shows A1. If it isn't, it shows B1.
Code:
=IF(B1="",A1,B1)
If however, you're trying to see whether B1 has a numeric value (then show it in C1), or is blank or has a text value (then show A1 in C1) then you could use something like this.
Code:
=IF(OR(ISTEXT(B1),B1=""),A1,B1)
Hope it helps.
 

Forum statistics

Threads
1,171,790
Messages
5,877,508
Members
433,264
Latest member
Donnybrook

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
Top