Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run Word from Excel VBA
Excel Experts, I would like to create code in an Excel VBA module that will run a Word macro I have saved in a word document. If the file containing the Word macro is "C:\netcap macros.doc", and the Word macro is named "Sub PrintSLKFiles", what Excel VBA code would run this macro. Thanks in advance, Alan -- achidsey |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Run Word from Excel VBA
Sub Test() Dim WordApp As Object Set WordApp = CreateObject("Word.Application") LetterTemplate = "C:\TestDoc.doc" With WordApp .Documents.Open LetterTemplate .Visible = True .Run ("Macro1") End With WordApp.Quit Set WordApp = Nothing End Su -- Kaa ----------------------------------------------------------------------- Kaak's Profile: http://www.excelforum.com/member.php...nfo&userid=751 View this thread: http://www.excelforum.com/showthread.php?threadid=49324 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Need Excel count of 1 word if found in multi-word cells of column | Excel Worksheet Functions | |||
Excel 7, paste linked to word becomes black when word pdf'd | Excel Discussion (Misc queries) | |||
Copy from Word to Excel, and retain indent, plus word wrap | Excel Discussion (Misc queries) | |||
Print labels by using Excel data in a Word mail into word | Excel Discussion (Misc queries) | |||
Printing Word Document using Excel Programming hangs Word | Excel Programming |