Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 231
  • Last Modified:

Webpage Redirection

Is it possible to open up and redirect a browser to a new page using visual basic? I have a button that when pressed has all kinds of things happening and then redirects you to a webpage.

Thanks,
Nik
0
NP2322
Asked:
NP2322
1 Solution
 
David LeeCommented:
I'm not clear on what you mean by "redirect".  It's possible to open a browser and navigate to a given page (i.e. URL) from within VB.  Is that what you have in mind?  If so, then the code fragment below demonstrates how to do this.

    Set objIE = CreateObject("InternetExplorer.Application")
    objIE.Navigate2 "http://www.yahoo.com"
    Do While objIE.readyState <> 4
        DoEvents
    Loop
    objIE.Visible = True
    Set objIE = Nothing
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now