Results 1 to 5 of 5

VBA Macro to Search a Website's Search-Box

Threaded View

unit285 VBA Macro to Search a... 11-18-2015, 05:32 PM
unit285 Re: VBA Macro to Search a... 12-04-2015, 10:13 AM
Marc L Re: VBA Macro to Search a... 12-05-2015, 07:51 PM
unit285 Re: VBA Macro to Search a... 12-06-2015, 02:33 AM
Marc L Re: VBA Macro to Search a... 12-06-2015, 02:35 PM
  1. #1
    Valued Forum Contributor unit285's Avatar
    Join Date
    10-29-2015
    Location
    TN
    MS-Off Ver
    Office 365
    Posts
    358

    VBA Macro to Search a Website's Search-Box

    Hello, I am trying to make a macro that will search a specific website's Search-Box

    So far my macro works ok for searching Google but will not work for FinViz. Any Help is Greatly Appreciated!

    Current Macro:
    Private Sub CommandButton1_Click()
    
    
        Application.ScreenUpdating = False
         
         
        UserSearch = Range("H8")
        Set IE = CreateObject("InternetExplorer.Application")
        IE.Visible = True
        IE.Navigate "http://finviz.com/"
         
         
        Application.StatusBar = "Submitting"
         ' Wait while IE loading...
        While IE.Busy
            DoEvents
        Wend
         ' **********************************************************************
        delay 1
        IE.Document.getElementById("lst-ib").Value = UserSearch
        delay 1
        SendKeys "{Enter}"
         '**********************************************************************
        Application.StatusBar = "Submitted"
         'IE.Quit
        Set IE = Nothing
         
         
        Application.ScreenUpdating = True
    End Sub
     
     
    Private Sub delay(seconds As Long)
        Dim endTime As Date
        endTime = DateAdd("s", seconds, Now())
        Do While Now() < endTime
            DoEvents
        Loop
    
    End Sub
    Last edited by unit285; 11-18-2015 at 06:01 PM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Need macro to search sourcode of a website
    By freak11 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-18-2014, 06:27 PM
  2. Replies: 0
    Last Post: 10-16-2013, 10:58 AM
  3. [SOLVED] Macro/s to create Search Bar to filter to search terms entered activated by Command Button
    By JasonRay in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-08-2013, 03:44 PM
  4. [Help Needed] Macro Excel for Search in Website
    By sdas86 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-23-2012, 06:13 AM
  5. [SOLVED] Macro ignores search code when 1 of the 2 search parameters is not found
    By BrodyNoochie in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-25-2012, 05:21 PM
  6. [SOLVED] VBA and Website Input and Search
    By abousetta in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-19-2012, 05:04 PM
  7. Replies: 0
    Last Post: 11-05-2009, 04:47 AM

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