+ Reply to Thread
Results 1 to 2 of 2

Retrieve Data From Website Page

Hybrid View

  1. #1
    Registered User
    Join Date
    12-23-2007
    Posts
    47

    Retrieve Data From Website Page

    I found this code on a site but was unable to identify the programmer. I need to fix one problem I have with the code. When I log into my specific site, after entering the login and password I get a window that pops asking me if I would like to proceed. How do I select the yes button on the pop up?


    Sub LoginToURL() 
        Dim ie As Object, strURL As String, strUsername As String, strPassword As String 
         
        Set ie = CreateObject("InternetExplorer.Application") 
         
        strURL = "http://www.skytronic.co.uk/product/index.php?s=128.685" 
        strUsername = "guest" 
        strPassword = "password" 
         
        ie.Navigate strURL 
         'Wait until page is loaded.
        While ie.ReadyState < 4 ' READYSTATE_COMPLETE = 4
            DoEvents 
        Wend 
         
        ie.Visible = True 
         
        ie.Document.All("username").Value = strUsername 
        ie.Document.All("password").Value = strPassword 
        ie.Document.All("submit").Click 
         
         'Wait until page is loaded.
        While ie.ReadyState < 4 ' READYSTATE_COMPLETE = 4
            DoEvents 
        Wend 
         
        Application.Wait (Now + TimeValue("0:00:05")) 
         
        urldownloadtofile http://www.skytronic.co.uk/product/index.php?s=128.685.txt 
         
    End Sub
    Last edited by dgkindy; 06-15-2009 at 08:40 AM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Retrieve Data From Website Page

    Please change your PHP tags to CODE tags.
    Entia non sunt multiplicanda sine necessitate

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1