Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
open word file?
How do I open a word file from excel. I have a vast amount of
information which I want to link to word documents which are all kept in the same folder. However, there are too many of these links so I can't just create hyperlinks. Instead I need a code to select the file once the certain cell is selected. The word files are all the same with the exception of a number, i.e. WORD001, WORD002, WORD003, etc. I have come up with this which selects the cell as a target. What is the code which will open the word document. Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Left(Target, 3) = "BOM" Then Open ("S:\Technical Support\ then the wordname. in this example, it will be target. MsgBox Target End If Will this code work? What is the open command? Any help is appreciated. Thanks. --- Message posted from http://www.ExcelForum.com/ |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
open word file?
Some places to start:
http://support.microsoft.com/?id=149830 XL: Macro to Link a Range of Cells in Word (Example of Excel controlling word) http://support.microsoft.com/?id=165926 OFF97: Can't Dimension Word as Application from Other Program (Examples of Working with Word 97 using OLE) http://support.microsoft.com/?id=135082 Invalid Page Fault Running VB Macro in Hidden Word Session (Word 7, when Word is Closed causes a problem) http://support.microsoft.com/?id=167223 Microsoft Office 97 Automation Help File Available on MSL -- Regards, Tom Ogilvy "pgoodale" wrote in message ... How do I open a word file from excel. I have a vast amount of information which I want to link to word documents which are all kept in the same folder. However, there are too many of these links so I can't just create hyperlinks. Instead I need a code to select the file once the certain cell is selected. The word files are all the same with the exception of a number, i.e. WORD001, WORD002, WORD003, etc. I have come up with this which selects the cell as a target. What is the code which will open the word document. Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Left(Target, 3) = "BOM" Then Open ("S:\Technical Support\ then the wordname. in this example, it will be target. MsgBox Target End If Will this code work? What is the open command? Any help is appreciated. Thanks. --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to open a new instance of Word and its .doc file | Excel Worksheet Functions | |||
Hyperlink to open Word File | Excel Discussion (Misc queries) | |||
Word and Excel crash when I try to open a folder to get to a file | Excel Discussion (Misc queries) | |||
when opening a .xls file it seems to want to open in word, what d | Excel Discussion (Misc queries) | |||
Graph Excel Selection, Open Word File, Embed Graph Into Word | Excel Programming |