Template Help!

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

I am creating a template where when I open the document a box pops up, I
fill in the info and then press ok to have the info inserted in the document.
Everything is working fine except that when I press ok the info is inserted
but the box will not close. If I press "ok" again the info is inserted again
and then closes.

How do I get to where I press "ok" once and the pop up closes?

Thanks
 
Hello,

It depends on how you are getting the pop-up. If a Fill-In field it will run
once when you create a new document based on your template. If an ASK field,
it needs to be triggered to run by a macro. See the tutorial on Ask fields
and Fill-In fields at http://addbalance.com/word/download.htm. If a
UserForm, you would create the code to close your dialog box when you are
finished with it. http://word.mvps.org/FAQs/Userforms/CreateAUserForm.htm
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide

See also the MVP FAQ: http://www.mvps.org/word which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 
Hi Charles,

Thanks for responding. I am using Userform and I tried that page. The code
that I wrote to close the box does not work. Any reason for this not to work?
 
You should post this in the vba.userforms newsgroup, with the code that
isn't working and details on what is happening.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide

See also the MVP FAQ: http://www.mvps.org/word which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 
Back
Top