Microsoft KB Archive/94782

= Clipboard Not Cleared After Restart in Interpreter Environment =

PSS ID Number: 94782

Article Last Modified on 1/8/2003

-

The information in this article applies to:


 * Microsoft Visual Basic for MS-DOS 1.0

-



This article was previously published under Q94782



SYMPTOMS
Text stored in the clipboard using the SetText method incorrectly remains even after restarting your program in the interpreter environment.



WORKAROUND
To work around the problem, put a Clipboard.Clear statement in your program before using the clipboard.



STATUS
Microsoft has confirmed this to be a bug in both the Standard and Professional Editions of Microsoft Visual Basic version 1.0 for MS-DOS. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.



Steps to Reproduce Problem
 Start VBDOS.EXE. From the File menu, choose New Form. Place a Command button (Command1) on the form and set the Caption property to SetText. Place another Command button (Command2) on the form and set the Caption property to GetText. From the File menu, choose Exit, and save all changes.  Add the following code to the Command1_Click event procedure: Sub Command1_Click Clipboard.SetText &quot;ON THE CLIPBOARD&quot; End End Sub </li>  Add the following code to the Command2_Click event procedure: Sub Command2_Click Print Clipboard.GetText End Sub </li> Run the program.</li> Click the SetText command button.</li> Press SHIFT+F5 to restart the program.</li> Choose the GetText command button.</li></ol>

At this point, you will see that the text did not clear when the program restarted.

Additional query words: VBmsdos buglist1.00 1.00

Keywords: KB94782

Technology: kbAudDeveloper kbVB100DOS kbVBSearch kbZNotKeyword3

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© 2004 Microsoft Corporation. All rights reserved.