FIX: Long Field Names May Cause GP Fault in VB.EXELast reviewed: October 30, 1997Article ID: Q113281 |
3.00
WINDOWS
kbinterop kbprg kbbuglist
The information in this article applies to: - Microsoft Visual Basic programming system for Windows, version 3.0
SYMPTOMSVisual Basic may generate a general protection (GP) fault when attempting to compile or run from within the environment or in VB.EXE at 002F:????. The offset may vary. 002F:08AF, 002F:0293, 002F:0860 were reproduced in testing with the code in this article.
CAUSEWhen Visual Basic attempts to parse the code for compilation as it is creating an EXE or attempting to run from within the Visual Basic environment, a GP fault occurs if the field name accessed by the Table object is longer than 41 characters and there is a space in the name. If you do not have a space in the name, Visual Basic will give you an "Identifier too long" error message.
WORKAROUNDReplace the problem line of code to avoid the problem. For example, using the code listed in the "Steps to Reproduce Problem" below: Replace: TB![AFieldNameThisLong CausesTheUAEPromlemInVBEXE] = 6 ' Problem line of code with: X$ = "AFieldNameThisLong CausesTheUAEPromlemInVBEXE" TB.Fields(X$).value = 6or: TB.Fields("AFieldNameThisLong CausesTheUAEPromlemInVBEXE").Value = 6
STATUSMicrosoft has confirmed this to be a bug 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.
MORE INFORMATION
Steps to Reproduce ProblemTo re-create the problem, you must first create the sample database with the long field name in it. This can be done using the Data Manager (DATAMGR.EXE).
|
Additional reference words: buglist3.00 GPF gp-fault fixlist4.00
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |