Microsoft KB Archive/78380

= BUG: Using Nonstandard Icons Can Cause UAE/GP Fault/Hang =

Article ID: 78380

Article Last Modified on 12/12/2003

-

APPLIES TO


 * Microsoft Visual Basic 2.0 Standard Edition
 * Microsoft Visual Basic 3.0 Professional Edition
 * Microsoft Visual Basic 2.0 Professional Edition
 * Microsoft Visual Basic 3.0 Professional Edition
 * Microsoft Visual Basic 1.0 Standard Edition

-



This article was previously published under Q78380



SYMPTOMS
If you create an icon in other than standard .ICO format and attach that icon to a Visual Basic form, you may get an Unrecoverable Application Error (UAE) in Windows version 3.0, a General Protection (GP) fault in Windows version 3.1, or your computer may hang (stop responding) and require you to turn the computer off to get out of it.

Icons in other than standard format might include a picture of how the icon looked when minimized or pasted directly to the form.

Nonstandard icons can also cause less severe run-time errors such as &quot;Invalid Picture.&quot; The icon will load at design time but cause problems at run-time.



STATUS
Microsoft has confirmed this to be a bug in the Microsoft 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
Icons created with utilities other than IconWorks -- even those created with the Windows Software Development Kit (SDK) Paint utility -- can cause problems because they may not conform to the standard .ICO format.

The standard .ICO format that Visual Basic supports is a 32 by 32 pixel matrix, which is specified in the icoDIBSize field in the header of the resource file. Because icons are handled as resources, once they are incorporated into the .EXE file, they can actually corrupt the code, which can cause the computer to hang during execution or cause a UAE or GP fault.

