Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
In my script, I delete two columns one by one using the following
two lines of code: .Columns(1).EntireColumn.Delete .Columns(1).EntireColumn.Delete Can one command do the job instead of two? Thanks. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
..Columns(1).Resize(,2).EntireColumn.Delete
-- Regards, Tom Ogilvy "John Smith" wrote in message ... In my script, I delete two columns one by one using the following two lines of code: .Columns(1).EntireColumn.Delete .Columns(1).EntireColumn.Delete Can one command do the job instead of two? Thanks. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
All of these work and there are more available...
Columns("A:B").Delete Range("A1:B1").EntireColumn.Delete Range(Columns(1), Columns(2)).Delete -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Smith" wrote in message two lines of code: .Columns(1).EntireColumn.Delete .Columns(1).EntireColumn.Delete Can one command do the job instead of two? Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2007 calculate time between 2 date/time columns | Excel Discussion (Misc queries) | |||
How to delete or copy alternative rows/columns at a time? | Excel Discussion (Misc queries) | |||
How do I delete multiple empty columns in Excel at one time? | Excel Discussion (Misc queries) | |||
merge text from 2 columns into 1 then delete the old 2 columns | Excel Worksheet Functions | |||
Delete same Rows/Columns from two worksheets at a time | Excel Programming |