Hi Becky;
"Didn't work." is hard to diagnosed....
Here are the instructions again, but with a bit more details:
(Also, please, next time, post your answer in the same thread to make sure
there is a continuity, if I hadn't notice your name, I would not have made
the connection... And somebody else reading your second thread may not be
able to help if they cannot make the connection with the other thread. That
is the power of the newsgroups: you have a problem, I try to help, someone
else comes along and gives another solution, or help you further...)
So...
Copy the code below:
Select it from "Sub..." to "End Sub";
Hit CTRL-C to copy it to the clipboard;
Open your form template:
Paste the code below in a module:
ALT-F11 to open the VBE;
Find your template in the list on the left (the tree view,
you should see "TemplateProject(Your_Template_Name_here)"
or "Project(Your_Template_Name_here)";
Right-click on this name;
Choose to insert a module (not a Class Module or a UserForm):
Paste the code in the code window on the right (Hit CTRL-V);
Close the VBE window;
Insert a bookmark where you want the signature to appear:
(Here the bookmark is called "bkmBossSig" in the code
it must bear the same name in your template and in the code);
Place the cursor where you will want the signature to appear;
From the "Insert" menu, choose "Bookmarks...";
Type a name;
Click "Add";
Create an autotext from the signature:
Insert the image somewhere;
select it (Just click on it once);
From the "Insert" Menu, choose "Autotext";
In the sub menu, choose "Autotext..." again;
Give it a name ("BossSig" for the code below to work);
At the bottom of the Autotext dialog,
there is a dropdown list: "Look in:";
Make sure to select your template name in
the list (Not Normal.dot);
Click on Add;
Add a button on a toolbar to call this macro:
Right-click any toolbar;
Choose "Customize...";
Click on the "Commands" tab;
In the "Categories" list on the left, select "Macros";
Find the macro in the "Commands" list on the right
(Something like "TemplateProject.Module1.InsertSignature");
Click on the name in the list and drag it to a toolbar;
Right-click on the newly created button;
Change the button name to something you like, anything is better
than "TemplateProject.Module1.InsertSignature" which is what
it will be after you drag it from the list onto the toolbar;
Hit Enter;
Click "Close" on the "Customize" dialog;
Lock your template for forms;
Save your template.
Close your template.
Create a document based on the template.
Click on the toolbar button you created above;
The signature should appear at the place where you had created the
bookmark.
If it still does not work, and you still want it to work, please write back
with specifics.
'_______________________________________
Sub InsertSignature()
Dim SigPlace As Range
ActiveDocument.Unprotect
Set SigPlace = ActiveDocument.Bookmarks("bkmBossSig").Range
AttachedTemplate.AutoTextEntries("BossSig").Insert _
Where:=SigPlace
ActiveDocument.Protect _
Type:=wdAllowOnlyFormFields, NoReset:=True
End Sub
'_______________________________________
--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site:
http://www.word.mvps.org
Becky said:
I tried doing the macro as outlined previously, but can't get the thing to
work. When I create an autotext from the signature, do I have to leave it
showing on the form somewhere? What I did was: created the autotext, deleted
the picture afterward, followed all the rest of the instructions. Didn't
work.