Microsoft KB Archive/231927

From BetaArchive Wiki

Article ID: 231927

Article Last Modified on 11/23/2006



APPLIES TO

  • Microsoft Outlook 2000 Standard Edition



This article was previously published under Q231927


SUMMARY

This article describes how to display a Web page on an Outlook custom form page.

MORE INFORMATION

Microsoft provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with the programming language being demonstrated and the tools used to create and debug procedures. Microsoft support professionals can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific needs. If you have limited programming experience, you may want to contact a Microsoft Certified Partner or the Microsoft fee-based consulting line at (800) 936-5200. For more information about Microsoft Certified Partners, please visit the following Microsoft Web site:

For more information about the support options that are available and about how to contact Microsoft, visit the following Microsoft Web site:


You can create a custom form in Outlook that displays a Web page directly on the form using the Microsoft Web Browser Control. This control is part of the Shdocvw.dll file, which is installed with Microsoft Internet Explorer.

How to Create a Custom Form to Display a Web Page

  1. On the File menu, point to New, and then click Mail Message.
  2. In the message, on the Tools menu, point to Forms and then click Design This Form.
  3. Click the (P.2) page of the form.
  4. On the Form menu, click Control Toolbox.
  5. In the toolbox, right-click a blank area on the Controls page, and then click Additional Controls.
  6. In the Available Controls list, click Microsoft Web Browser Control, and then click OK.
  7. In the toolbox, click the WebBrowser control and drag it to the form page.
  8. In the toolbox, click a CommandButton and drag it to the form page.
  9. On the Form menu, click View Code.
  10. In the Script Editor, type the following code and then close the Script Editor.

    Sub CommandButton1_Click()
       Set MyPage = Item.GetInspector.ModifiedFormPages("P.2")
       MyPage.WebBrowser1.Navigate("http://www.microsoft.com")
    End Sub
                        
  11. On the Form menu, click Run This Form to run the form.
  12. Switch to the P.2 page and click CommandButton1 to display the Web page.


REFERENCES

For additional information about available resources and answersto commonly asked questions about Microsoft Outlook 2000 solutions, click the article number below to view the article in the Microsoft Knowledge Base:

146636 OL2000: Questions About Custom Forms and Outlook Solutions



Additional query words: OutSol OutSol2000 vbscript

Keywords: kbhowto kbprogramming KB231927