Andy Lacey
andy at minstersystems.co.uk
Wed Nov 5 16:17:34 CST 2003
Hi Virginia
With the Word libray referencec it's
objWord.Close wdDoNotSaveChanges
Andy Lacey
http://www.minstersystems.co.uk
> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of
> Hollis,Virginia
> Sent: 05 November 2003 21:09
> To: 'Access Developers discussion and problem solving'
> Subject: RE: [AccessD] Open Word Document
>
>
> Perfect, thanks.
>
> When you open a document in Word is there anyway to prevent
> it from asking if you want to save changes? Why does it show
> the Save message when no changes have been made - only opened
> the document? I have noticed Excel does the same thing,
> always wanting to save changes.
>
> Va.
>
> -----Original Message-----
> From: Bryan Carbonnell [mailto:Bryan_Carbonnell at cbc.ca]
> Sent: Wednesday, November 05, 2003 2:45 PM
> To: accessd at databaseadvisors.com
> Subject: Re: [AccessD] Open Word Document
>
>
> Here is some Quick & Dirty code:
>
> dim objWord as Object
>
> set objWord = CreateObject("Word.Application")
> objWord.visible = true
>
> objWord.Documents.Open "C:\FullPath\to\DocToOpen.doc",,True
>
> set objWord = Nothing
>
> No references to the Word TypeLibrary are needed.
>
> THe True in this line:
> objWord.Documents.Open "C:\FullPath\to\DocToOpen.doc",,True
>
> Tells Word to open the document as read only.
>
> Bryan Carbonnell
> bryan_carbonnell at cbc.ca
>
> >>> HollisVJ at pgdp.usec.com 05-Nov-03 3:28:55 PM >>>
> How do you open a Word Document from a form?
>
> I have an instruction guide in Word that I would like to
> access from a form & have the Word document open Read Only. I
> tried a hyperlink, but could not find the properties to open
> the document read-only. I know I could set the document
> properties to read-only, but looking for a different way to
> open and set the properties.
>
> Virginia
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/a> ccessd
> Website:
> http://www.databaseadvisors.com
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/a> ccessd
> Website:
> http://www.databaseadvisors.com
>
>