Word 2007 letter template - open saved document are missing vba code

P

pmm

I have build a template with some vba-code to handle userinput with at
userdefined
dialogbox. After the dialogbox is closed the data is placed in the
document.
I have also added a button to the ribbon, so the userdialogbox can be
showed again,
with the data from the document in the userdefined dialobox. It works
fine.
Then I save the document as xxxx.docm (document with macro).

Now the problem: When the document is open again the macrocode and
then button in the
ribbion is missing!
I have tried to add trusted locations where the template and the
document are saved,
(also remembered Subfolders) but that was not the solution. If the
document is saved
as Word 97-2003 format, it works as expected (is works fine). But why
is it a problem
with the Word 2007 format?

I will be very happy if someone can solve this problems for me.
 
P

pmm

I have build a template with some vba-code to handle userinput with at
userdefined
dialogbox. After the dialogbox is closed the data is placed in the
document.
I have also added a button to the ribbon, so the userdialogbox can be
showed again,
with the data from the document in the userdefined dialobox. It works
fine.
Then I save the document as xxxx.docm (document with macro).

Now the problem: When the document is open again the macrocode and
then button in the
ribbion is missing!
I have tried to add trusted locations where the template and the
document are saved,
(also remembered Subfolders) but that was not the solution. If the
document is saved
as Word 97-2003 format, it works as expected (is works fine). But why
is it a problem
with the Word 2007 format?

I will be very happy if someone can solve this problems for me.

Hey

I have »solved« it by myself
The problem was that I have procted some sections, and when I remove
the protection it works fine again.
But then there are new problems! I now missed the protection. I have
tryed to use the new controll-element, but every time I update the
text »field« the text got the color grey. And I have tryed to use
styles, but it dont work. So I have new problems - I will now try
harder to got control over controll-element...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top