03-13-2014, 09:04 PM
I have gotten a little farther:
this will open the doc in non-locked mode but doesn't show any form field count even when I am using a document made from a template with lots of fields.
Until some fields are recongized then the actions on FormFields index/bookmark can't occur.
When I try this:
I get the result
Error (RT) in Macro: 0x800A1735,
The requested member of the collection does not exist
I think I am getting closer but can't figure out why the VB doesn't recognize the fields.
Thanks for any thoughts,
S
VARIANT filepath = "C:\Pick the date.docx"
VARIANT s
typelib Word {00020905-0000-0000-C000-000000000046} 8.0
Word.Application oApp._create
Word.Document oDoc = oApp.documents.open(filepath s s)
oApp.Visible = "true"
out oDoc.FormFields.Count
oDoc.Close
oApp.Quit
;
this will open the doc in non-locked mode but doesn't show any form field count even when I am using a document made from a template with lots of fields.
Until some fields are recongized then the actions on FormFields index/bookmark can't occur.
When I try this:
VARIANT filepath = "C:\Pick the date2.docx"
VARIANT s
typelib Word {00020905-0000-0000-C000-000000000046} 8.0
Word.Application oApp._create
Word.Document oDoc = oApp.documents.open(filepath s s)
oApp.Visible = "true"
out oDoc.FormFields.Count
VARIANT t = "TestField"
oDoc.FormFields.Item(t).Result = "John Doe"
I get the result
Error (RT) in Macro: 0x800A1735,
The requested member of the collection does not exist
I think I am getting closer but can't figure out why the VB doesn't recognize the fields.
Thanks for any thoughts,
S