Results 1 to 3 of 3
  1. #1
    5 Star Lounger
    Join Date
    Mar 2001
    Posts
    989
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Delete 'numbered' columns (Excel 2003)

    I would like to use numbers to delete columns. For example, to delete the third to the fifth column (rather than columns C-E). Is there a simple way I can use the Columns collection to do this? I'm hoping for an instruction such as 'Columns(3,5).Delete'? Thanks, Andy.

  2. #2
    Plutonium Lounger
    Join Date
    Nov 2001
    Posts
    10,550
    Thanks
    0
    Thanked 7 Times in 7 Posts

    Re: Delete 'numbered' columns (Excel 2003)

    There may be an easier way to do this, but this works.

    <code>Range(ActiveWorkbook.ActiveSheet.Columns(3), ActiveWorkbook.ActiveSheet.Columns(5)).Delete</code>

    StuartR

  3. #3
    5 Star Lounger
    Join Date
    Mar 2001
    Posts
    989
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Delete 'numbered' columns (Excel 2003)

    Thank you. Not as 'gorgeous' as I would like, but does the job. Andy.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •