Copy table from protected area

D

dsyropushchinsky

Hi,

I need to copy a table (with forms) from protected area to
unprotected. Preferably macro should be able to paste several table
consequently if user needs to. Unfortunately I'm just a beginner with
VBA, so I'd greatly appreciate your help.
 
P

Pranav Vaidya

Hi,
I hope you want to copy the tables from one doc to another.
You can use the tables collection to move from one table to the next until
the last table in the doc.
also define a range object which starts at the table starts and ends at the
table ends, for example

dim myRange as Range
dim mTbl as Table

For Each mTbl in ActiveDocument.Tables
set myRange=Activedocument.Range(mTbl.Rows(1).Range.Start),
mTbl.Rows(mTbl.Rows.Count).Range.End))
myRange.Select
Selection.Copy
..
..
..

Next

Regards
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top