#1
|
|||
|
|||
open several word docs
hello
anyone knows how to do a vba code to open 10 files of word at the same time? thanks |
#2
|
|||
|
|||
Does his help...
Method 1: Brute force way, just run Document.Open 10 times, each pointing to the full path of your documents. Code:
Documents.Open FileName:="doc1.docx" Documents.Open FileName:="doc2.docx" Documents.Open FileName:="doc(n).docx" This could be useful if you're getting your doc names programmatically. Code:
Dim arr_docs(9) As String ' Create a fixed sized array for 10 items. ' Populate each item in the array arr_docs(0) = "doc1.docx" arr_docs(1) = "doc2.docx" ' etc ' With all your docs stored in the array, loop through them to open them all. For each doc in arr_docs Documents.Open FileName:=doc Next doc |
#3
|
||||
|
||||
You may find Open Documents from List useful.
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
#4
|
|||
|
|||
thank you very much for the effort and help
best regards |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Treversing directories and open WORD-docs ??? | ksor | Word VBA | 0 | 10-14-2019 05:20 AM |
Cannot open older Word docs | chas1308 | Word | 5 | 05-20-2018 01:40 AM |
Can't open Word docs on server | macdude425 | Other Software | 3 | 12-06-2016 01:37 PM |
2016 Word for Mac - How open docs bigger? | wmth99 | Word | 0 | 12-25-2015 11:17 AM |
Word shuts down when trying to open certain docs | lesliejames | Word | 0 | 01-19-2015 11:36 AM |