When I create a new file from a template and save it as a document,
(.doc) and then close & re-open it, word still warns me that the .dot
file contains macros. And Project explorer shows all the elements in
the .dot file that creatd it.

How can i save the document created without the vba,macros and
userforms?

thanks
hals_left

Re: save file wihout vba macros by Peter

Peter
Wed Jun 22 15:39:24 CDT 2005

"hals_left" <cc900630@ntu.ac.uk> wrote in message
news:1119472485.098254.117350@g44g2000cwa.googlegroups.com...
> When I create a new file from a template and save it as a document,
> (.doc) and then close & re-open it, word still warns me that the .dot
> file contains macros. And Project explorer shows all the elements in
> the .dot file that creatd it.
>
> How can i save the document created without the vba,macros and
> userforms?
>
> thanks
> hals_left
>

That's what templates are for. There's no point in creating a doc from a
template if you do not want the tenplate's elements in the doc. You can
delete all the VBA stuff before saving the doc but it would be easier to
create a template that contains only what you want in the document.


--
Peter Aitken

Remove the crap from my email address before using.



Re: save file wihout vba macros by hals_left

hals_left
Wed Jun 22 15:54:39 CDT 2005

The VBA and Userform elements in the template are soley to populate
the doc with data from a database. Normally users would just print and
sent it by post. Now they want to email it - is there no way of saving
the finshed document without the vba code and userform ?

Is there another way to achieve this?

thanks.


Re: save file wihout vba macros by RBM

RBM
Wed Jun 22 16:05:03 CDT 2005

Conceptually, you could put all the required code in a global template
that is loaded on startup. It would then be there and available for
use when the document is created but not actually saved with the
document when it's saved.

On 22 Jun 2005 13:54:39 -0700, "hals_left" <cc900630@ntu.ac.uk> wrote:

> The VBA and Userform elements in the template are soley to populate
>the doc with data from a database. Normally users would just print and
>sent it by post. Now they want to email it - is there no way of saving
>the finshed document without the vba code and userform ?
>
>Is there another way to achieve this?
>
>thanks.


Re: save file wihout vba macros by hals_left

hals_left
Wed Jun 22 16:17:15 CDT 2005

Thanks, I will take a look at global templates.


Re: save file wihout vba macros by Charles

Charles
Wed Jun 22 16:41:31 CDT 2005

Save your templates in a regular templates folder. 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. Then set your
macro security to trust installed templates and add-ins.
--

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.

"hals_left" <cc900630@ntu.ac.uk> wrote in message
news:1119472485.098254.117350@g44g2000cwa.googlegroups.com...
> When I create a new file from a template and save it as a document,
> (.doc) and then close & re-open it, word still warns me that the .dot
> file contains macros. And Project explorer shows all the elements in
> the .dot file that creatd it.
>
> How can i save the document created without the vba,macros and
> userforms?
>
> thanks
> hals_left
>



Re: save file wihout vba macros by hals_left

hals_left
Wed Jun 22 17:12:30 CDT 2005

Charles, that stops the macro warnings, thanks. But the docs created
and saved still contain the vba and form.


Re: save file wihout vba macros by hals_left

hals_left
Wed Jun 22 17:14:10 CDT 2005

Charles, that stops the macro warning, thanks. But the docs created and
saved still contain the templates vba and useforms.


Re: save file wihout vba macros by CarolineJ

CarolineJ
Thu Jun 23 08:57:03 CDT 2005

The docs created from the template only look like they have the code - but
the code is actually in the document template. If the template was removed
from the PC or the doc is opened on another PC without the template being
available the code would not be there. Also if the document is no longer
'attached' to the template the code will go.
To check you can try Tools, Templates and Addins from the menu, remove the
name of the template from the 'Document Template' box make sure
'Automatically update document styles' is not selected then click on OK.
This attaches the doc to Normal.dot and uses that as the document template.
Now if you check, the code will not be visible - unless of course it also
exists in your normal.dot (but it wouldn't if you emailed it to someone
without the template on the desktop either as the code is not in the doc but
in the tempalte).

Hope that helps and does not confuse

Caroline

"hals_left" wrote:

> Charles, that stops the macro warning, thanks. But the docs created and
> saved still contain the templates vba and useforms.
>
>