Microsoft KB Archive/828822

= Shape Comparison Fails Through a VBA Event =

Article ID: 828822

Article Last Modified on 1/12/2006

-

APPLIES TO


 * Microsoft Office Visio Professional 2003
 * Microsoft Office Visio Standard 2003

-





SYMPTOMS
If you disconnect and then reconnect the same dynamic connector to the same Microsoft Office Visio 2003 shape, a Microsoft Visual Basic for Applications (VBA) event handler that tracks these changes will indicate that different shapes were connected to instead of the same shape.



CAUSE
This problem occurs when you switch a Stencil pane to edit mode after you start the event handler and create the shapes and connectors. When you put a Stencil pane in edit mode, COM resets the properties for all objects on the drawing and resets the values any object variables to NULL. So when the VBA macro or event handler detects the change, the value for the shape has not been stored and comparison tests will indicate a different shape was connected to.

After this event occurs, subsequent disconnections and reconnections of the Dynamic connector from the shape will behave as expected, because the value is now stored in your comparison variable.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section of this article.

Additional query words: VSO11 VSO2003

Keywords: kbprb kbcode KB828822

-

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

© Microsoft Corporation. All rights reserved.