Programming Automation Into a .dot

S

Stanley

I have a protected .dot file that I am programming from MS Access 2002.
In my code I unprotect the document and then I can update fields that I set
as bookmarks.
My problems are:
a) I can't protect the documents again (objword.ActiveDocument.protect gives
me an error--the document is not open
b) I can't show the document on the screen
c) I don't know how to save the document with a given name

Let me tell you what I am trying to do.
I want to have a number to protected forms with bookmarks (filled in
programatically) and fields and controls for user entry.

After I fill the bookmarked fields, I want the user to see the form and fill
in the rest of it.

Then I want to save the document with a programmed name in a specific folder.

Thanks,
Stanley
 
D

Doug Robbins - Word MVP

Instead of bookmarks, use docvariable fields and have your Access routine
set the value of corresponding variables in the document and update the
fields in the document so that the values of the variables are displayed in
the docvariable fields. It is not then necessary to unprotect the document.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP, originally posted via msnews.microsoft.com
 

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