You receive an error message when you use a Windows Vista Sidebar gadget that has an event that is set to null

You receive an error message when you use a Windows Vista Sidebar gadget that has an event that is set to null

Article ID : 927825
Last Review : May 16, 2007
Revision : 1.5
On This Page

SYMPTOMS

When you use a Windows Vista Sidebar gadget, you receive an error message that resembles the following:

A Runtime Error has occurred. Do you wish to Debug? Line: <line number> Error: Unspecified error

.

Back to the top

CAUSE

This problem occurs if the gadget’s script code tries to set a gadget event to null. Sidebar gadget events cannot be set to null.

Back to the top

WORKAROUND

To work around this problem, assign a function to the Sidebar gadget event.

Back to the top

MORE INFORMATION

Steps to reproduce the problem

1. Open the gadget’s .html file.
2. Type the following code inside a <script> tag:

System.Gadget.ondock = myFunc;System.Gadget.ondock = null;

For more information about Sidebar gadgets, visit the following Microsoft Web site:

http://msdn2.microsoft.com/en-us/library/ms723694.aspx (http://msdn2.microsoft.com/en-us/library/ms723694.aspx)

Back to the top


APPLIES TO
• Windows Vista Ultimate
• Windows Vista Enterprise
• Windows Vista Business
• Windows Vista Home Premium
• Windows Vista Home Basic
• Windows Vista Ultimate 64-bit Edition
• Windows Vista Enterprise 64-bit Edition
• Windows Vista Business 64-bit Edition
• Windows Vista Home Premium 64-bit Edition
• Windows Vista Home Basic 64-bit Edition

Back to the top

Keywords: 
kbexpertiseinter kbtshoot kbscript kberrmsg kbprb KB927825

Back to the top

 

Microsoft Knowledge Base Article

This article contents is Microsoft Copyrighted material.
Microsoft Corporation. All rights reserved. Terms of Use | Trademarks


You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

AddThis Social Bookmark Button

Leave a Reply

*
To prove that you're not a bot, enter this code
Anti-Spam Image