D
Dragon
Hi. I am trying to write code to access autotext from a global template in
the Add-in list. I had tried both:
NormalTemplate.AutoTextEntries("Detention").Insert _
Where:=Selection.Range, RichText:=True
and
ActiveDocument.AttachedTemplate.AutoTextEntries("Detention").Insert _
Where:=Selection.Range, RichText:=True
but I get a 5941 error - object not found. I have proceeded the line with:
Set endff = ActiveDocument.FormFields(ActiveDocument.FormFields.Count)
endff.Select
to designate the last form field. The ActiveDocument command was working
fine when I was within the Template itself. Now that I am trying to access
the autotext from a different document, it isn't working.
I would be greatful for any assistanct.
Thanks.
the Add-in list. I had tried both:
NormalTemplate.AutoTextEntries("Detention").Insert _
Where:=Selection.Range, RichText:=True
and
ActiveDocument.AttachedTemplate.AutoTextEntries("Detention").Insert _
Where:=Selection.Range, RichText:=True
but I get a 5941 error - object not found. I have proceeded the line with:
Set endff = ActiveDocument.FormFields(ActiveDocument.FormFields.Count)
endff.Select
to designate the last form field. The ActiveDocument command was working
fine when I was within the Template itself. Now that I am trying to access
the autotext from a different document, it isn't working.
I would be greatful for any assistanct.
Thanks.