Article ID: 220420 - Last Review: June 17, 2005 - Revision: 2.0 WD2000: VBA: Text Placed in Wrong Document Using Hidden DocumentsThis article was previously published under Q220420 SYMPTOMS
When you try to add text to a document that was hidden using the Visible statement, you may receive unexpected results. For example, the following procedure demonstrates this behavior. In the following procedure, if you have a document open (MyDoc.doc) before running the procedure, when you run the procedure, a new document is created. Instead of the the text being inserted into the new document as expected, the text is inserted into MyDoc.doc: RESOLUTIONMicrosoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements. To resolve this problem, you can assign a variable to the Visual Basic for Applications Document object to access and manipulate the hidden document window. For example: STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
| Article Translations
|
Back to the top
