Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jason
 
Posts: n/a
Default Properties of a document, help!

hi, is there anyway that i could make a file open with microsoft word from
vba (excel), its a .out file, it could be opened by changing its properties
(open with) to word, but could it be done through coding?, please help
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default Properties of a document, help!

Something like

Dim oWordApp As Word.Application
Dim oWordDoc As Word.Document

Set oWordApp = New Word.Application
oWordApp.Visible = True
Set oWordDoc = oWordApp.Documents.Open(Filename:="filename")
'more code
Set oWordDoc = Nothing
oWordApp.Quit
Set oWordApp = Nothing

You will need to set a reference to the Microsoft Word library
(ToolsReferences)

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Jason" wrote in message
...
hi, is there anyway that i could make a file open with microsoft word from
vba (excel), its a .out file, it could be opened by changing its

properties
(open with) to word, but could it be done through coding?, please help



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jason
 
Posts: n/a
Default Properties of a document, help!

cheers bob

"Bob Phillips" wrote:

Something like

Dim oWordApp As Word.Application
Dim oWordDoc As Word.Document

Set oWordApp = New Word.Application
oWordApp.Visible = True
Set oWordDoc = oWordApp.Documents.Open(Filename:="filename")
'more code
Set oWordDoc = Nothing
oWordApp.Quit
Set oWordApp = Nothing

You will need to set a reference to the Microsoft Word library
(ToolsReferences)

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Jason" wrote in message
...
hi, is there anyway that i could make a file open with microsoft word from
vba (excel), its a .out file, it could be opened by changing its

properties
(open with) to word, but could it be done through coding?, please help




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Connect document properties to headers and footers Jeroen Excel Discussion (Misc queries) 1 October 31st 05 09:19 AM
Reference the document properties in a cell McVeigh Excel Worksheet Functions 1 September 29th 05 10:55 PM
How to embed Word document into Excel and retain sizing, formatti. Kent Excel Discussion (Misc queries) 0 February 2nd 05 07:37 PM
Document Properties in Header or Footer Rohullah Najafi Excel Discussion (Misc queries) 1 January 6th 05 02:59 PM
Excel document properties insert into a cell Mark Excel Discussion (Misc queries) 3 December 16th 04 02:05 PM


All times are GMT +1. The time now is 09:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"