WD6x: InsertFile Command Returns -1 for Both OK and CancelLast reviewed: February 3, 1998Article ID: Q139961 |
The information in this article applies to:
SYMPTOMSThe InsertFile command returns -1 for both OK and Cancel. This behavior is incorrect. The command should return 0 for Cancel and -1 for Insert.
WORKAROUNDWARNING: ANY USE BY YOU OF THE CODE PROVIDED IN THIS ARTICLE IS AT YOUR OWN RISK. Microsoft provides this macro code "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose. Use the following macro to work around the problem.
Sub MAIN On Error Goto Canc Dim dlg As InsertFile GetCurValues dlg Dialog dlg InsertFile dlg MsgBox "OK button pushed, file inserted." Goto done Canc: MsgBox "Cancel button pushed." done: End Sub STATUSMicrosoft has confirmed this to be a problem in the products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.
|
Additional query words: word basic
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |