> Hi Julie
> To be honest I've never worked with a DMS (the opportunity would be
nice!).
> So you're saying that the DMS denies you the opportunity to create a
> document based on a user specified template? The DMS's i've briefly seen
in
> action (very briefly!) at least allowed the user to create a document and
> then add it to the DMS.
> Anyway, one eay way around the problem is to add a boolean custom document
> property to your Master document with a value of True. Test this custom
> property in you Document_Open event and if True combine your 16 documents
> etc. Then set the custom property to False in the generated document to
> that the code is never triggered again. Here's the code:
> The following adds a Custom Document Property (Boolean i.e.: it's value is
> Yes or No):
> ActiveDocument.CustomDocumentProperties.Add "BuildDoc", _
> False, msoPropertyTypeBoolean, True
> To change the value of your Custom Document Property once you have created
> it use:
> ActiveDocument.CustomDocumentProperties("BuildDoc").Value = False
> To read the value of your Custom Document Property:
> If ActiveDocument.CustomDocumentProperties("BuildDoc").Value Then
> MsgBox "The custom property BuildDoc has a Yes value"
> Else
> MsgBox "The custom property BuildDoc has a No value"
> End If
> I wish I knew more about DMS's so that I could provide you with more
> insiteful help.
> Anyway, I hope this has been of help + Cheers - Peter
> > Hi Doug
> > I can't use templates due to the document management system in place ...
> > so i have a document called master.doc - which has a document open event
> > of a message box that says "do you want to combine the 16 documents
> > now?" on pressing Yes - a macro fires, that inserts 16 documents /
> > formats them to the original style definitions / adds a header in with
> > different page numbering for different sections / resets the outline
> > numbering back to 1 in each inserted section / inserts and formats a toc
> > and sets up the footer and then saves this document as Master2003.doc
> > However, my problem is that when you open Master2003.doc it fires the
> > same document_open code ... hence asking if you want to combine the 16
> > documents again - of course, the user can (should / must) press NO but i
> > feel this is ugly.
> > If you have any suggestions regarding this i would be most happy to hear
> > them.
> > Cheers
> > Julie
> >> Hi Julie,
> >> Well the obvious question is "Why do you have a Document_Open event in
> >> the document in the first place?"
> >> It seems to me that you probably should not have it there. Tell us why
> > and
> >> what it's doing and we might be able to give you an alternative.
> >> Please respond to the newsgroups for the benefit of others who may be
> >> interested.
> >> Hope this helps
> >> Doug Robbins - Word MVP
> >> > Hi Doug
> >> > Thanks for the suggestion - however, i need to keep styles, heading
> >> levels,
> >> > toc, linked & unlinked page numbers etc ... so i'm not sure that rtf
> >> > (although i've not done much using rtf) will work for me?
> >> > the way i've "worked around it" is to set a variable when the new
> > document
> >> > is created and then 1st thing in the Document_Open code is to check
> >> > the value of that variable.
> >> > This seems to work - but i was hoping for a way you can just save a
> > *.doc
> >> > with out the modules & code elements.
> >> > Cheers
> >> > Julie
> >> > > Hi Julie,
> >> > > If you save the document as an .RTF file, the code will be stripped
> > from
> >> > it.
> >> > > Please respond to the newsgroups for the benefit of others who may
> >> > > be interested.
> >> > > Hope this helps
> >> > > Doug Robbins - Word MVP
> >> > > > Hi All
> >> > > > I've a document that has Document_Open code that i'ld like to
> >> > > > remove
> >> > from
> >> > > > the document that is created by this code (if that makes sense).
> > When
> >> i
> >> > > do
> >> > > > a "Save As" i just want to keep the word part not the vba part.
> >> > > > I can't use a template to create the document (due to the
> >> > > > Document Management System and network setup).
> >> > > > Any ideas?
> >> > > > Cheers
> >> > > > Julie