FIX: DHTML Scriptlet Method Fails on 1,143rd Invocation (261959)



The information in this article applies to:

  • Microsoft Internet Explorer (Programming) 5
  • Microsoft Internet Explorer (Programming) 5.01

This article was previously published under Q261959

SYMPTOMS

When you access a DHTML scriptlet for the 1,143rd time, you receive the error message:
Object does not support this property or method.

RESOLUTION

For Microsoft JScript, wrap calls to the offending method inside of a try/catch block. For Microsoft Visual Basic Script (VBScript), use On Error Resume Next. After the 1,143rd call, the method should work again, so all you need to do is suppress the error once.

STATUS

This bug was corrected in Internet Explorer 5.5.

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that this article describes. Apply it only to systems that are experiencing this specific problem.

To resolve this problem, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

For Microsoft Internet Explorer 5.0, the English version of this fix should have the following file attributes or later:
   Date      Time    Version        Size      File name     Platform
   -------------------------------------------------------------
   01/24/2000 02:28a 5.0.2725.2400  2,355,472 Mshtml.dll    Intel
				
For Microsoft Internet Explorer 5.01, the English version of this fix should have the following file attributes or later:
   Date      Time    Version        Size      File name     Platform
   -------------------------------------------------------------
   03/16/2000 03:05p 5.0.3015.1600  2,352,912 Mshtml.dll    Intel
				


MORE INFORMATION

Steps to Reproduce Behavior

  1. Save the following DHTML scriptlet page as ScriptletLib.htm:
    <HTML>
    <HEAD>
    <TITLE></TITLE>
    </HEAD>
    <SCRIPT LANGUAGE=javascript id=Classes>
    
    public_description = new ScriptletLib();
    
    function ScriptletLib() // external methods declaration
    {
    	this.ScriptletMethod = ScriptletMethod;
    }
    function ScriptletMethod()
    {
    	return 0;
    }
    </SCRIPT>
    
    <BODY>
    </BODY>
    </HTML>
    					
  2. Save the following test file as ScriptletTest.htm:
    <HTML>
    <HEAD>
    <META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
    <TITLE></TITLE>
    
    <SCRIPT for=window event=onload LANGUAGE=javascript>
    var i = 0;
    alert("start");  
    
    for ( i = 0; i<2000; i++ ){
        window.status = "Access #" + i;
        //try { 
        ScriptletLib.ScriptletMethod();
        //} catch(e) {
        //}
    }
    alert("End");  
    
    </SCRIPT>
    
    </HEAD>
    <BODY  bgcolor="#ffffff">
    
    <OBJECT id=ScriptletLib name=ScriplettLib classid="CLSID:AE24FDAE-03C6-11D1-8B76-0080C744F389">
    	<PARAM NAME="URL" VALUE="ScriptletLib.htm">
    </OBJECT>
    
    </BODY>
    </HTML>
    					
  3. Execute ScriptletTest.htm. The error message described in the "Symptoms" section will appear.
  4. To suppress this error, uncomment the try/catch statements in ScriptletTest.htm.

REFERENCES

For more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites:

Modification Type:MajorLast Reviewed:5/11/2006
Keywords:kbBug kbDHTML kbfix kbie550fix KB261959