Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Tables in Word macros

Options
  • 10-03-2005 12:22pm
    #1
    Moderators, Arts Moderators Posts: 35,471 Mod ✭✭✭✭


    Has anyone any experience of dealing with tables in Word macros? Basically, I want to be able to select or ignore any text in a particular document which is within a table, or even select/delete the table itself.


Comments

  • Registered Users Posts: 14,714 ✭✭✭✭Earthhorse


    Not sure how different VBA is for Word as opposed to Excel, would have thought they were the same. Have you tried:
    Word.Application.ActiveDocument.Tables(6).Rows(3).Delete
    

    If you want to delete the 3rd row of the sixth table in your document.

    Not sure if a table has a delete method itself. If you delete all the rows from the table it's the same result. Just make sure you work from the last row, or table, to the first.

    Hope that helps.


Advertisement