Visual Basic Concepts

Testing your Internet Component Download

See Also

Testing your download file is more complex than testing a conventional setup program because the software does not install unless one of two things is true:

Because of this, you must be careful when you test your download to ensure that you test both scenarios. As a developer, you should test your application on multiple machines with varying configurations. At a minimum, you should test the download on both your development machine and on a machine that does not have Visual Basic installed, and on multiple operating systems. In addition, you must check your safety levels.

Note   If you do not have a machine without Visual Basic installed, you can simulate one. See "Testing Component Download on Clean Machines" for instructions.

Setting Safety Levels Prior to Testing

Before testing your download, be sure the safety level in Internet Explorer is set to Medium. If the safety level is set to High, the required files will not get downloaded. If you set the safety level to None, all of the missing components will be installed without warning.

When the safety level is set to Medium, the following warnings occur:

These warnings are all part of the Internet Explorer's safety mechanisms. If you do not receive all of these warnings, do not be alarmed. You may not receive a warning if a necessary component is already installed on the client machine or a security level option in Internet Explorer is set to something other than the defaults.

To check the safety level in Internet Explorer 4. x

  1. Click Internet Options from the View menu.

  2. From the Options dialog box, click the Security tab.

  3. Click the appropriate safety level, then click OK.

To check the safety level in Internet Explorer 3.x

  1. Click Options from the View menu.

  2. From the Options dialog box, click the Security tab.

  3. Click the Safety Levels button.

  4. Click the appropriate safety level, then click OK.

  5. Click OK to return to the browser.

Testing Safety Levels

You can check safety levels by creating additional .cab files and HTML pages for testing, as suggested in the following table:

To test pages with Create a page that hosts a control with
No initialization or scripting No PARAM values or other variables set by the control.
Initialization only PARAM values assigned to a control.
Scripting only PARAM values set by VBScript only.
Scripting and initialization Initial PARAM values set and then modified by VBScript.