No announcement yet.

Web Browser Object Problem

  • Filter
  • Time
  • Show
Clear All
new posts

  • Web Browser Object Problem

    Hi.. Im woundering if anyone can help me. I'm trying to place a web browser object on my autorun program... I have no problem with getting it to display a webpage within the dirstribution directory if I specifiy "%SrcDir%\book1.htm" in the initial page display option, but I want the user to be able to click a text object and then have it set the webrowser to
    "%SrcDir%\book2.htm" or even simply "%SrcDir%\book1.htm" again. Under the text object i have the following PageShow.Object("WebBrowser1") (i have it showing because it starts off as hidden) and I also have
    WebBrowserObject[WebBrowser1].NavigateTo ("%SrcDir%\book1.htm")
    The problem is when I click the Text Object at Runtime the Web Browser displays with a 404 error and the autorun proram gives me this error "Could not go to specified URL. The Object was not found on this page. 'WebBrowser1'". The only way I can get the web borwser to display a page is by saetting it in th einitial url thing.. Any suggestions? It won't even Navigate to Help Please..

  • #2
    Re: Web Browser Object Problem

    have you tried to put a sleep command between the show property and the navigate.To Action? I am wondering if it doesn't have time to show the object before it tries to navigate to the new page.

    Have you tried this with the WebBrowser visible? That may help to answer the above question.

    Or you may try the Is Visible command to make sure that it is visible before proceeding

    WebBrowserObject (WebBrowser), Navigate.To ("path to file")
    Application.Sleep (5)
    Goto redo

    Or maybe a While Loop

    WHILE (!%IsVisible%)
    Application.Sleep (1)
    WebBrowserObject (WebBrowser), Navigate.To ("path to file")

    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools."
    "Draco dormiens nunquam titillandus."
    Map of IR Forum Users - IR Project CodeViewer - Online Help - TiggTV - QuizEngine


    • #3
      Re: Web Browser Object Problem

      Thanx it worked... i got one more quick question, but I will start a new thread as to get more attention [img]/ubbthreads/images/icons/smile.gif[/img]