2 Replies - 546 Views - Last Post: 21 December 2011 - 09:04 AM Rate Topic: -----

Topic Sponsor:

#1 bruntale  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 12
  • Joined: 03-June 09

Sentence/Keyword Finder on Webpage AutoHotKey

Posted 20 December 2011 - 10:48 PM

keywordlist := "orange,blue,green,purple,white,black,yellow,red"
Sentence := "Please click on the BLUE, ORANGE, GREEN, YELLOW, BLACK, WHITE, RED square to continue"
; StringReplace Sentence, Sentence, `,, %A_Space%, A

SetTitleMatchMode, 2

IfWinExist, Firefox
	WinActivate

Loop Parse, Sentence, %A_Space%
{
   WordToTest := A_LoopField
    ; Msgbox % WordToTest
    Loop Parse, keywordlist, `,
    {
      KeyWord := A_LoopField
        ; Msgbox % KeyWord
      If (InStr(WordToTest, KeyWord, False))
          Msgbox Color found : %WordToTest%
    }
}
exitapp




That is my script for Auto Hot Key.


I am wondering where I went wrong. I want it to:

1. Activate Window

2. Search for a sentence on web page.

3. Find keyword in webpage.


As you can see in the script what the sentence is and the keywords. Where did I go wrong? It doesn't seem to want to search the page. It brings the webpage to the front.

Is This A Good Question/Topic? 0
  • +

Replies To: Sentence/Keyword Finder on Webpage AutoHotKey

#2 BobRodes  Icon User is offline

  • Your Friendly Local Curmudgeon
  • member icon

Reputation: 321
  • View blog
  • Posts: 1,941
  • Joined: 19-May 09

Re: Sentence/Keyword Finder on Webpage AutoHotKey

Posted 21 December 2011 - 08:05 AM

What language is this?
Was This Post Helpful? 0
  • +
  • -

#3 bruntale  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 12
  • Joined: 03-June 09

Re: Sentence/Keyword Finder on Webpage AutoHotKey

Posted 21 December 2011 - 09:04 AM

Auto Hot Key = AHK

http://www.autohotkey.com/
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1