Microsoft KB Archive/179135

= BUG: Polygon ATL Sample Fails to Work in Internet Explorer 4.0 =

Article ID: 179135

Article Last Modified on 12/11/2003

-

APPLIES TO


 * Microsoft Internet Explorer 4.0 128-Bit Edition
 * Microsoft Internet Explorer 3.0
 * Microsoft Internet ActiveX Controls 1.0
 * Microsoft Visual C++ 5.0 Enterprise Edition
 * Microsoft Visual C++ 5.0 Professional Edition
 * Microsoft ActiveX Template Library 3.0
 * Microsoft ActiveX Template Library 2.1

-



This article was previously published under Q179135



SYMPTOMS
The PolyCtl.htm file that comes with the Polygon Active Template Library (ATL) sample, hosts the Polygon control in a Web page. This Web page increases the number of sides of the polygon when the user clicks inside the polygon and decreases the number of sides when the user clicks outside the polygon. However, in Internet Explorer 4.0, mouse clicks appear to have no affect on the number of sides of the polygon.



CAUSE
This is a bug in the PolyCtl sample. The first time the Polygon control is activated in Internet Explorer 4.0, it calculates its bounding rectangle incorrectly. This causes the control to interpret ClickOut events as ClickIn events.



RESOLUTION
To work around this problem, write script code to handle the Window_OnLoad event. In this event handler, set the number of sides to 3 or to any value that you desire.

Implement the following code to work around this problem:  



STATUS
This problem has been corrected in the POLYGON sample shipped with Visual C++ 6.0.

Additional query words: PolyCtl Polygon

Keywords: kbbug KB179135

-

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

© Microsoft Corporation. All rights reserved.