npuleio
asked on
creating a word document by WordApplication with custom template
Hello everyone,
anyone could suggest me how I can create a new word document from a custom template authenticated by user/password with WordApplication not visible so I can update only two places automatically then saving in another folder and printing as PDF?.....
Thanks to all!
Ciao,
Luigi
anyone could suggest me how I can create a new word document from a custom template authenticated by user/password with WordApplication not visible so I can update only two places automatically then saving in another folder and printing as PDF?.....
Thanks to all!
Ciao,
Luigi
What language are you trying to write this program in?
ASKER
Hello,
I use C++ Builder...
I use C++ Builder...
Then you should be in that application zone. I will move the question for you. I doubt if you're going to get any answers in the Word forum.
Joanne Orzech
MS Word MVP
EE Zone Advisor
Joanne Orzech
MS Word MVP
EE Zone Advisor
Oh my apologies evilrix! And my thanks for straightening this out....
Joanne
Joanne
>> thanks for straightening this out
No worries, my pleasure.
No worries, my pleasure.
ASKER
At least, anyone knows why if I write:
WordApplication->ActiveDoc ument->Sha pes->AddTe xtEffect(m soTextEffe ct1, "text", "Arial Black", 1, msoFalse, msoFalse, 0, 0)
C++ Builder couldn't find a match?...
WordApplication->ActiveDoc
C++ Builder couldn't find a match?...
ASKER
OK here I am... I did some investigations and tests around Word.Application....
I have a template .dot which has read-password and write-password... how I would set the wordapplication as here:
WordDoc = WordDocs.OleFunction("Add" , OleVariant(path_of_templat e_name.dot ,...)
to pass automatically passwords?....
If I do
WordDoc = WordDocs.OleFunction("Add" , OleVariant(path_of_templat e_name.dot ,false, 1);
then
WordDoc.OlePropertySet("Pa sswordTemp late") = passwordtemplate;
WordDoc.OlePropertySet("Wr itePasswor dTemplate" ) = passwordtemplate;
indeed executing OleFunction(...), Word opens and asks me directly the password instead of executing OlePropertySet... how I can figure that out?...
Thanks
Ciao
Luigi
I have a template .dot which has read-password and write-password... how I would set the wordapplication as here:
WordDoc = WordDocs.OleFunction("Add"
to pass automatically passwords?....
If I do
WordDoc = WordDocs.OleFunction("Add"
then
WordDoc.OlePropertySet("Pa
WordDoc.OlePropertySet("Wr
indeed executing OleFunction(...), Word opens and asks me directly the password instead of executing OlePropertySet... how I can figure that out?...
Thanks
Ciao
Luigi
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.