Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 08-05-2014, 10:26 AM
Faugs Faugs is offline Creating VBA Code to Delete Empty Column in Table Windows 7 32bit Creating VBA Code to Delete Empty Column in Table Office 2010 32bit
Novice
Creating VBA Code to Delete Empty Column in Table
 
Join Date: Aug 2014
Posts: 5
Faugs is on a distinguished road
Smile Creating VBA Code to Delete Empty Column in Table

Hi all,



I've been stuck on this for very long and would appreciate any help whatsoever!

I've created a mail merge that populates a table in Word. The table will be populated with the account's sales for 1 of 6 eligible product groups (see below)


However, if the account has no sales for a specific product group (Mobile PC - Column 2), then some of the cells are left blank (see below).


I'd like to create a VBA code that would detect if any cells are blank within the table and if so, delete the entire column (see final result below, Mobile PC column is deleted).


I have been deleting each column manually in the past, but have now been tasked with completing these letters once a week. We have thousands of accounts which means I have to manually delete thousands of columns each week.

Any help would be so appreciated, thank you!
Attached Images
File Type: jpg 1.JPG (60.5 KB, 55 views)
File Type: jpg 2.JPG (57.4 KB, 54 views)
File Type: jpg 3.JPG (52.6 KB, 54 views)
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating VBA Code to Delete Empty Column in Table Macro to delete all empty rows from all tables braddgood Word VBA 15 10-02-2015 01:54 PM
Creating VBA Code to Delete Empty Column in Table Delete row when 2 column has no value Rok Word VBA 1 11-26-2013 01:59 AM
Creating VBA Code to Delete Empty Column in Table Unable to open or delete an empty folder Zimm Windows 4 11-19-2013 05:07 PM
Delete lots of empty space between paragraphs. FieldTechnician Word 4 10-25-2013 01:14 PM
Creating VBA Code to Delete Empty Column in Table Macro to delete rows with all empty cells ubns Excel Programming 2 08-14-2012 02:01 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 11:03 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft