![](/img/trans.png)
[英]How to open a word document and find text in it without showing the document?
[英]How to open a word document without resolving the attached template?
由於從Office 2000到Office 2010的遷移,我的單詞模板名稱已更改(從* .dot更改為* .dotm)。 現在,我想更新現有文檔中指定的附加模板的聲明。 我寫了一些映射“舊”和“新”模板名稱的過程,但是在檢索舊模板名稱時遇到了麻煩。 當使用Documents.open()
打開文檔時,找不到指定的附加模板,因此將Normal.dotm作為默認應用,並且我的映射不起作用。 我沒有找到關閉附加模板自動解析的方法。 奇怪的行為:打開文檔后,原始模板名稱可以在文檔屬性中看到,但?ActiveDocument.AttachedTemplate
是'Normal.dotm'
嘗試這個:
MsgBox Dialogs(wdDialogDocumentStatistics).Template
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.