Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
User form
Thanks to some help from here, I have set up a userform letter head which
allows people to very simply open a template letterhead, insert a team name in the header section, and adress and telphone number in the footer...all works quite well. One problem... protection. I guess I am missing some VBA code to maintain the protection. Basicall when they open the form a menu pops up, which they complete and the info is then place in the header and the footer of the document. They then type up the body of the letter. I have 3 bookmarks (team name in header, adress and tel. no in footer), plus the body of the letterhead is a "comment" field to allow the user to enter the body of his letter. However, even thought i have password protected the .dot file, it is no longer there when I re-open the .dot file, or when I go "open" "new" "template" Basically, I want the user to be able open the template and inserts his 3 pieces of info. After that he has access only to the body of the letter (and if necessary his 3 pieces of info). I dont want him to be able to change the base text and logo's in the header and the footer. MVP site and Dian site helped with basic set up, but I cannot undrestand hoe to complete protection. Here is my VBA code: Private Sub CommandButton1_Click() With ActiveDocument .Bookmarks("TeamCategory").Range _ .InsertBefore teamCategory .Bookmarks("Adress").Range _ .InsertBefore adress .Bookmarks("Telephone").Range _ .InsertBefore phoneno End With UserForm1.Hide End Sub Thanks for your help. Mark |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
User form
Hi ?B?TWFyaw==?=,
You don't mention which commands you're using to activate protection. Is it Tools/Protect, and you're protecting for a form? some thoughts... 1. I don't know what you mean by a "comment" field, either. But from the sound of it, what you should be doing is inserting a continuous section break, then protecing Section 1 (that will lock out the headers/footers), leaving Section 2 unprotected. This way, the user can edit the body of the letter (Section 2) using most of the usual formatting commands. 2. The most common cause for forms protection being lost is saving the file in a non Word-Document file format, such as RTF. Are you certain the document is being saved AND opened as a Word document (*.doc)? 3. Which version of Word are you using? Thanks to some help from here, I have set up a userform letter head which allows people to very simply open a template letterhead, insert a team name in the header section, and adress and telphone number in the footer...all works quite well. One problem... protection. I guess I am missing some VBA code to maintain the protection. Basicall when they open the form a menu pops up, which they complete and the info is then place in the header and the footer of the document. They then type up the body of the letter. I have 3 bookmarks (team name in header, adress and tel. no in footer), plus the body of the letterhead is a "comment" field to allow the user to enter the body of his letter. However, even thought i have password protected the .dot file, it is no longer there when I re-open the .dot file, or when I go "open" "new" "template" Basically, I want the user to be able open the template and inserts his 3 pieces of info. After that he has access only to the body of the letter (and if necessary his 3 pieces of info). I dont want him to be able to change the base text and logo's in the header and the footer. MVP site and Dian site helped with basic set up, but I cannot undrestand hoe to complete protection. Here is my VBA code: Private Sub CommandButton1_Click() With ActiveDocument .Bookmarks("TeamCategory").Range _ .InsertBefore teamCategory .Bookmarks("Adress").Range _ .InsertBefore adress .Bookmarks("Telephone").Range _ .InsertBefore phoneno End With UserForm1.Hide End Sub Cindy Meister INTER-Solutions, Switzerland http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004) http://www.word.mvps.org This reply is posted in the Newsgroup; please post any follow question or reply in the newsgroup and not by e-mail :-) |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
MULTIPLE INSTANCES OF THE SAME BOOKMARK IN A USER FORM | Microsoft Word Help | |||
Form creations - attachment enclosed. | Page Layout | |||
text form field and spaces | Microsoft Word Help | |||
How to create a word form such that user can format the font. | Microsoft Word Help | |||
How can a user change the default date in a form field? | Tables |