PDA

View Full Version : [SOLVED] Delete Blank Columns and Delete Blank Columns



pycoh
03-05-2015, 01:55 PM
I have a very big csv file approx 800 columns and 6500 rows sometimes even more.

1st. since this is a huge file, i need a macro deleting blank columns. row 1 has a label on it. so i want to delete that as well, only if there are no values on that row.
2nd. i need to delete blank rows as well.

can this be activated individually? because i want to check the datas first after deleting the blank columns?

hope someone can help me out on this.

Thanx in advance!

ashleyuk1984
03-05-2015, 04:06 PM
This will give you a good start.

Delete Columns

Rows("1:1").SpecialCells(xlCellTypeBlanks).EntireColumn.Delete

Delete Rows

Columns("A:A").SpecialCells(xlCellTypeBlanks).EntireRow.Delete

pycoh
03-05-2015, 04:15 PM
ashleyuk:

thank you! ill try that. :)