Microsoft KB Archive/159923

From BetaArchive Wiki

Article ID: 159923

Article Last Modified on 9/5/2006



APPLIES TO

  • Microsoft Internet Explorer 3.0
  • Microsoft Internet Explorer 3.01
  • Microsoft Internet Explorer 3.02
  • Microsoft Internet Explorer 4.0 128-Bit Edition
  • Microsoft Internet Explorer 4.01 Service Pack 2
  • Microsoft Internet Explorer 4.01 Service Pack 1
  • Microsoft Internet Explorer 4.01 Service Pack 2
  • Microsoft Internet Explorer 5.0
  • Microsoft Internet Explorer 5.01
  • Microsoft Internet Explorer (Programming) 5.01 SP1
  • Microsoft Internet Explorer 5.5
  • Microsoft Internet Explorer (Programming) 5.5 SP1
  • Microsoft Internet Explorer (Programming) 5.5 SP2



This article was previously published under Q159923

SUMMARY

A licensed ActiveX control does not load correctly in an Internet Explorer HTML page if the computer is not licensed to use the control. For example, if you use Microsoft Visual C++ to build the control, the HTML page loads with the control on the computer where it was built, but it does not load on a different computer.

To use licensed controls in an HTML page on a non-licensed computer, you must generate a license package (.lpk) file. The .lpk file contains the run-time licenses for licensed controls in the HTML page. You can use the License Package Authoring Tool (Lpk_tool.exe) to generate this file. To obtain the License Package Authoring Tool, visit the following Microsoft Web site:

back to the top

Steps to add a control to an HTML page

To embed a licensed control on an HTML page, follow these steps:

  1. Run Lpk_tool.exe on a computer that is licensed to use the control.
  2. Highlight each licensed ActiveX control that you want to use on the HTML page, and then click Add.
  3. Click Save & Exit, and then type a name for the LPK file.
  4. In the HTML page, insert an <OBJECT> tag for the License Manager object before any other <OBJECT> tags. The License Manager is an ActiveX control that is installed with Internet Explorer.

    Note This CLASSID, "5220cb21-c88d-11cf-b347-00aa00a28331", is for the License Manager and not for your ActiveX controls. You must use the same CLASSID every time you refer to the LPK file. In addition, you should keep the Name property of the <PARAM> tag as "LPKPath", and set the Value property for the <PARAM> tag of the License Manager object to the LPK file name and path. This path may be a relative path but must not refer to a UNC share or a URL on another domain.

    Because you can only have one LPK file for each HTML page, make sure that you include all of the licensed ActiveX Controls for the page when you generate your LPK file. For example:

    <OBJECT CLASSID = "clsid:5220cb21-c88d-11cf-b347-00aa00a28331" VIEWASTEXT>
       <PARAM NAME="LPKPath" VALUE="relative URL to .LPK file">
    </OBJECT>
                        
  5. Insert the <OBJECT> tag for your licensed control afterward. For example, an HTML page that displays the Microsoft Masked Edit control looks like this:

    <OBJECT CLASSID="clsid:5220cb21-c88d-11cf-b347-00aa00a28331" VIEWASTEXT>
    <PARAM NAME="LPKPath" VALUE="maskedit.lpk">
    </OBJECT>
    
    <OBJECT CLASSID="clsid:C932BA85-4374-101B-A56C-00AA003668DC"
    WIDTH=100 HEIGHT=25 VIEWASTEXT>
    </OBJECT>
                        

back to the top

Troubleshooting

Before you use a licensed control in a Web page, verify the following items:

  1. Verify that you have a redistribution license for the control.
  2. Verify that the license permits use on the Internet.
  3. If you supply a CodeBase parameter for the <OBJECT> tag of your ActiveX Control, verify that its use is allowed by your license agreement. Most third parties companies provide a tested version of the .cab files for their controls. Refer to the author documentation for software download instructions.

To verify this information, consult the license agreement for the control in question. The term "All Rights Reserved" means that you only have permission to do what is explicitly stated. Any activity that is not allowed (or is vague) in the license agreement is a possible license violation.

Note ActiveX controls that come with Microsoft Visual C++ and Microsoft Visual Basic are also licensed controls. Follow the steps above to use them on an HTML page. Microsoft provides a signed version of these .cab files. For more information, see the "References" section.

back to the top

REFERENCES

For additional information about CAB file distribution, click the following article numbers to view the articles in the Microsoft Knowledge Base:

172991 CAB files distributed with Visual Basic 5.0


For additional information about the Internet component download process, click the following article numbers to view the articles in the Microsoft Knowledge Base:

264570 WebCast: How does Internet component download work?


252937 How to find more information about why code download failed


271594 Internet component download online troubleshooter is available


271273 Second licensed ActiveX control does not load


back to the top


Additional query words: msmask32 ocx grid32

Keywords: kbhowtomaster kbdownload kbctrl kbfaq kbcode KB159923