SAVE docuemtn from template

S

String

I made a template in WORD
But what am trying to do now is that
When the template is open should be a wdDialogFileSaveAs should be started
But when the user clicks on cancel the template should be closed and not be
used anymore

i thought of solving it like that

MsgBox "SAVE befor you start … "

activedocument.Saved = False
CommandBars.FindControl(ID:=3).Execute

If activedocument.Saved Then
' MsgBox "The document was saved."
' If MsgBox("you dont want to save the doc? ?", vbYesNo +
vbQuestion, SAVING) = vbNo Then
' activedocument.Close
'
activedocument.Close
RecentFiles(1).Open
yesNo = yes
Else
MsgBox "somting "



But i always get Error or it doesn’t work good ..
Help .. any tips ?
 
C

Charles Kenyon

If the template is properly used, you don't need all this.

The way to use a template is to put it in one of the templates folders. Then
use File > New and select your template. This creates a brand new document
based on your template. When it is saved, the Save As dialog pops up
defaulted to a document type of document and the user assigns a name.

The only time one opens a document template is to make changes to the
template, not to create a new document. For more on the different kinds of
templates, tabs on the file new dialog, and locations of templates folders
see http://addbalance.com/usersguide/templates.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


--------- --------- --------- --------- --------- ---------
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.
 
S

String

i know that .. but
what if the template is somewhere server and you have a group of more than
100 users ? u don’t expect me to go do so in all workstations ??


thx anyway :)
 
C

Charles Kenyon

There are things called office policies. They can be set at installation.

I do expect you to set up each workstation so that it can access workgroup
templates. The best way is probably to have log-in scripts that update local
copies. See http://word.mvps.org/FAQs/MacrosVBA/DistributeMacros.htm.

This is what IT departments are for.

Sending templates out to be opened so that they can create documents is
compounding your problems, not solving them!
--
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


--------- --------- --------- --------- --------- ---------
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.
 

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