FireFox Posted February 12, 2009 Share Posted February 12, 2009 Hi, I want to know if its possible to get first web site link of google search results like when you click on "I'm Feeling Lucky" without navigate... Thanks for anyhelp or idea Cheers, FireFox. Link to comment Share on other sites More sharing options...
monoceres Posted February 12, 2009 Share Posted February 12, 2009 Something like this maybe? #include <ie.au3> $searchterm=StringReplace("AutoIt Wikipedia"," ","+") $ie=_IECreate("http://www.google.com/search?hl=en&q="&$searchterm&"&btnG=Google+Search&aq=f&oq=",0,0) $links=_IELinkGetCollection($ie) $i=0 For $link In $links If $i=23 Then MsgBox(0,$link.innerText,$link.href) ExitLoop EndIf $i+=1 Next _IEQuit($ie) Broken link? PM me and I'll send you the file! Link to comment Share on other sites More sharing options...
FireFox Posted February 12, 2009 Author Share Posted February 12, 2009 @monoceres Thanks for your suggestion, but I want to do it without navigate, like a direct link Cheers, FireFox. Link to comment Share on other sites More sharing options...
monoceres Posted February 12, 2009 Share Posted February 12, 2009 Got it! #include <ie.au3> $searchterm = StringReplace("AutoIt Wikipedia", " ", "+") $url = "http://www.google.com/search?hl=en&q=" & $searchterm & "&btnI=I%27m+Feeling+Lucky&aq=f&oq=" $answer = MsgBox(68, "?", "Direct link to AutoIt Wikipedia is:" & @CRLF & $url & @CRLF & "Navigate now?") If $answer = 6 Then ShellExecute($url) AlienStar 1 Broken link? PM me and I'll send you the file! Link to comment Share on other sites More sharing options...
FireFox Posted February 12, 2009 Author Share Posted February 12, 2009 @monoceres Thanks, you rock ! Cheers, FireFox. Link to comment Share on other sites More sharing options...
AlienStar Posted January 24, 2018 Share Posted January 24, 2018 On 2/12/2009 at 9:47 PM, monoceres said: Got it! #include <ie.au3> $searchterm = StringReplace("AutoIt Wikipedia", " ", "+") $url = "http://www.google.com/search?hl=en&q=" & $searchterm & "&btnI=I%27m+Feeling+Lucky&aq=f&oq=" $answer = MsgBox(68, "?", "Direct link to AutoIt Wikipedia is:" & @CRLF & $url & @CRLF & "Navigate now?") If $answer = 6 Then ShellExecute($url) amazing tip how can I do the same for image search please ?? Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted January 24, 2018 Moderators Share Posted January 24, 2018 (edited) @AlienStar did you happen to notice this thread is over 9 years old? Please don't resurrect old posts, especially when what you're asking has absolutely NOTHING to do with the original question. Start a new thread instead, include a detailed description of what you're trying to accomplish, along with what you have tried on your own, and we will do our best to assist. Edited January 24, 2018 by JLogan3o13 AlienStar 1 "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
AlienStar Posted January 24, 2018 Share Posted January 24, 2018 Just now, JLogan3o13 said: @AlienStar did you happen to notice this thread is over 9 years old? Please don't resurrect old posts, especially when asking a completely different question. Start a new thread instead, include a detailed description of what you're trying to accomplish, along with what you have tried on your own, and we will do our best to assist. oh sorry I didn't notice its date I'll make a new thread Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now