Remove Blank Cells From a Column Range

ststern45

Well-known Member
Joined
Sep 17, 2005
Messages
965
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
Hi everyone,

I have random letters from a through z in cell range DB12 through DS12.
Some of these cells contain blanks and no repeat letters
I'm looking for a formula that will place the letters from DB12 through DS12 starting in cell DW12.

Thank you in advance!!
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
I'm looking for a formula that will place the letters from DB12 through DS12 starting in cell DW12.
That is a very incomplete description.
- Starting in DW12 and then going in which direction?
- Do you want the blank spaces removed?
- Do you want them sorted in any specific order?

All these questions can usually be answered pretty quickly with a visual example of your data and expected results.
 
Upvote 0
That is a very incomplete description.
- Starting in DW12 and then going in which direction? DW12 through EN12
- Do you want the blank spaces removed? Yes
- Do you want them sorted in any specific order? No order

All these questions can usually be answered pretty quickly with a visual example of your data and expected results.
Thank you!!
 
Upvote 0
Since all the cells contain text is there a workaround similar to this formula below?
If I'm not mistaken the aggregate only will calculate values not text.
=IFERROR(AGGREGATE(15,6,$DB12:$DS12/($DB12:$DS12<>"")/(ISNA(MATCH($DB12:$DS12,DV12:$DV12,0))),1),"")
Thanks!!
 
Upvote 0
Found the formula here at MrExcel:

=IFERROR(INDEX($DB12:$DS12, SMALL(IF($DB12:$DS12<>"", COLUMN($DB12:$DS12)-COLUMN($DB12)+1, ""), COLUMNS($DW12:DW12))), "")
Ctrl + Shift + Enter
 
Upvote 0
If you are interested, you could also use this one that does not require the Ctrl+Shift+Enter confirmation (can be useful in case formulas ever need to be amended where the C+S+E might be forgotten)

Excel Formula:
=IFERROR(INDEX($DB12:$DS12,AGGREGATE(15,6,(COLUMN($DB12:$DS12)-COLUMN($DB12)+1)/($DB12:$DS12<>""),COLUMNS($DW12:DW12))),"")
 
Upvote 0
If you are interested, you could also use this one that does not require the Ctrl+Shift+Enter confirmation (can be useful in case formulas ever need to be amended where the C+S+E might be forgotten)

Excel Formula:
=IFERROR(INDEX($DB12:$DS12,AGGREGATE(15,6,(COLUMN($DB12:$DS12)-COLUMN($DB12)+1)/($DB12:$DS12<>""),COLUMNS($DW12:DW12))),"")
Thank you Peter.
I have not checked your formla.
Will this work with text/ alpha characters also?
 
Upvote 0

Forum statistics

Threads
1,216,099
Messages
6,128,823
Members
449,470
Latest member
Subhash Chand

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