The information in this article applies to:
SYMPTOMS
When using arrays of user-defined types (UDTs) with a With statement inside
a For loop, Visual Basic will not unlock the array when exiting the loop
with an Exit For statement. If you attempt to re-dim or erase the array,
the following run-time error is received:
RESOLUTIONAvoid using Exit For inside a With statement. A GoTo statement should be used instead. STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this bug and will post new information here in the Microsoft Knowledge Base as it becomes available. MORE INFORMATION
The array is locked because an array element is being pointed at by the
With statement. The array is unlocked when you exit the With statement
normally at End With, but is not unlocked when you exit the With statement
early with Exit For.
Steps to Reproduce Behavior
REFERENCES
For additional information, please see the following article in the
Microsoft Knowledge Base:
Q176049 : BUG: Run-time Error "This Array is Fixed or Temporarily Locked" Additional query words: kbDSupport kbdss kbVBp500bug kbNoKeyWord kbVBp600bug
Keywords : kbGrpVB |
Last Reviewed: January 5, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |