Automatically Load Web Page on PowerPoint Slide

D

Duane Sears

In Microsoft Knowledge Base Article, 253699, the following
subroutine is provided for "automatically" loading a web
page into a Webbrowser embedded on a slide. However this
subroutine is slightly flawed because the slide has to be
viewed at least once in Show mode at before the web page
will actually load. After that, if you visit the slide a
second time (even after closing and restarting Show mode,
but not closing the file), the web page will always load
whenever you visit the slide in Show mode. Does anyone
know how to modify the visual basic code so that a web
page will load the first time the slide is actually
viewed??
=================================
Sub <WebBrowserN>_DocumentComplete(ByVal pDisp As Object,
URL As Variant)
Dim varURL As Variant

' Check to see if this is the first time this
' control has been run, if so, load the page.
If URL = "" Then
varURL = "http://www.microsoft.com"
WebBrowser1.Navigate varURL
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top