Jump to content
Sign in to follow this  
Rickname

FF.au3 error :( - and can't manage to do it :(

Recommended Posts

Rickname

I downloaded FF.au3 , installed MozRepl, started it, put 4242 as port in it, then when Im trying to run this simple script :

#include "FF.au3"
_FFConnect(default,Default,6000)

_FFWindowOpen("http://www.youtube.com", True, True)

The thing is, it actually works, but it is still gives me a very annoying error :

 

_FFConnect: OS:    WIN_7 WIN32_NT 7601 Service Pack 1
_FFConnect: AutoIt:    3.3.12.0
_FFConnect: FF.au3:    0.6.0.1b-10
_FFConnect: IP:    127.0.0.1
_FFConnect: Port:    4242
_FFConnect: Delay:     2ms
_FFConnect: Socket:     488
_FFConnect: Browser:    Mozilla/5.0 (Windows NT 6.1; rv:30.0) Gecko/20100101 Firefox/30.0
__FFSendJavaScripts: Sending functions to FireFox .......... done
_FFWindowOpen: http://www.youtube.com
_FFLoadWait: .
__FFWaitForRepl ==> Error TCPSend / TCPRecv: TCPRecv :-1

__FFWaitForRepl ==> Error TCPSend / TCPRecv: TCPRecv :-1
. loaded in 573ms
[object XrayWrapper [object HTMLDocument]] - {location: {...}, SWFUpload_0: function() {...}, rss_feed: {...}, getElementsByName: function() {...}, getItems: function() {...}, open: function() {...}, close: function() {...}, ...}
_FFWindowGetHandle: 0x00000000
_FFWindowGetHandle ==> General Error

 

What can do ? :(

Edited by Rickname

Share this post


Link to post
Share on other sites
Rickname

You may want to review the suggested changes in >this post.

 

It works partially, still the function can't retrieve the handle of the created window :

The only error that disappeared was the TCP error :/

 

_FFConnect: OS:    WIN_7 WIN32_NT 7601 Service Pack 1

_FFConnect: AutoIt:    3.3.12.0

_FFConnect: FF.au3:    0.6.0.1b-10

_FFConnect: IP:    127.0.0.1

_FFConnect: Port:    4242

_FFConnect: Delay:     2ms

_FFConnect: Socket:     488

_FFConnect: Browser:    Mozilla/5.0 (Windows NT 6.1; rv:30.0) Gecko/20100101 Firefox/30.0

__FFSendJavaScripts: Sending functions to FireFox .......... done

_FFWindowOpen: http://www.youtube.com

_FFLoadWait: . loaded in 85ms

[object XrayWrapper [object HTMLDocument]] - {location: {...}, getElementsByName: function() {...}, getItems: function() {...}, open: function() {...}, close: function() {...}, write: function() {...}, writeln: function() {...}, ...}

_FFWindowGetHandle: 0x00000000

_FFWindowGetHandle ==> General Error

__FFSendJavaScripts: Sending functions to FireFox .......... done

Edited by Rickname

Share this post


Link to post
Share on other sites
Gonnosuke

This is a known issue with _FFWindowOpen. It's trying to set extended with the hWnd from a FF window that isn't yet selected. It's wonky. Try the following and the final attempt to get the handle should succeed:

_FFStart("http://www.youtube.com")

_FFWindowSelect()

Or

_FFConnect(Default, 4242, 6000)
_FFWindowOpen("http://www.youtube.com", True, True)
_FFWindowSelect()

 

P.S. When you see LoadWait results like this: "_FFLoadWait: . loaded in 85ms" you can be reasonably sure it's a selection problem. MozRepl is many great things, but fast isn't one of them!

Edited by Gonnosuke
  • Like 1

Share this post


Link to post
Share on other sites
Rickname

Thankyou Gonnosuke :)

So the final solution is this :

_FFStart("http://www.youtube.com")

_FFWindowSelect()

The other sol with WindowOpen doesn't work !

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Similar Content

    • vati1011
      By vati1011
      Hey, guys.
      Currently, I'm using Opencv UDF and i'm  encountering issues with DLLOPEN(). it is failing and returning -1
      But, I cannot figure out why it is failing.
      I need help from people.
      I'm running windows 10 32bit.
      This's my code.
      #RequireAdmin $fileopen = DllOpen("opencv_core2413.dll") MsgBox(0,"Result",$fileopen) Example.au3opencv_core2413.dll
    • tommytx
      By tommytx
      ConsoleWrite("Hello Dolly on Line 1" & @CRLF) #include <IE.au3> ConsoleWrite("Hello Dolly on Line 5" & @CRLF) Local $oIE = _IECreate("www.autoitscript.com") ConsoleWrite("Hello Dolly on Line 10" & @CRLF) Can anyone put me on the right track to troubleshoot this one.. the IE browser is not opening.. it is not my primary browser since FF is but that has not been a problem in the past.. it all seems to work including compile but the generation of the IE browser.. Never had any problem before.. below is the results of the run.. any ideas on where I might look.. that is the only error i get and its only after a 30 second delay.. I suppose a time out..
       
      ; >"C:\Program Files (x86)\AutoIt3\SciTE\..\autoit3.exe" /ErrorStdOut "G:\show_pos.au3\test.au3"
      ; Hello Dolly on Line 1
      ; Hello Dolly on Line 5
      ; --> IE.au3 T3.0-2 Error from function _IECreate,  (Browser Object Creation Failed)
      ; Hello Dolly on Line 10
      ; >Exit code: 0    Time: 30.46
       
    • ohaya
      By ohaya
      Hi,
      I am still really new with AutoIT.  We are using it to automate logging into web sites and I have encountered problems with focus.  The target web page is configured to put the cursor into the first text field (username) when the page is loaded, and when I run the AutoIT script, which does the log in seems like it is just not starting where I expect it to be.  
      I have been kind of using ToolTip() to kind of help with debugging, but now I am wondering if the calls to ToolTip() are causing the focus to be messed up.  
      For example, at least visually, when the ToolTip() is called, I can see the cursor disappear from the web page text field and they when I do anything that is supposed to send keystrokes, they are going off somwhere else ("never-neverland").
      But when I remove some of the ToolTip() calls, it works correctly.
      So the questions I have are:
      1) Do the ToolTip() calls interfere with/change where the focus on the target page are?
      2) In general, what are the "rules" for where ToolTip can be used "safely" (== doesn't interfere with focus)?
      Thanks,
      Jim
       
    • xiantez
      By xiantez
      This script used to work on an older version of AutoIT. Currently I am running AutoIT v3.3.14.5 and it's failing.
      Func PublicIP() ;Post public facing IP address Local $url = 'https://www.google.com/search?client=opera&q=what+is+my+ip&sourceid=opera&ie=UTF-8&oe=UTF-8' Local $getIPaddress = BinaryToString(InetRead($url)) Local $sStart = 'clamp:2">' Local $sEnd = '</div>' Local $ipaddress = _StringBetween($getIPaddress, $sStart, $sEnd For $i In $ipaddress MsgBox(0, 'External IP', "Your public IP address is " & $i) Next EndFunc ;==>PublicIP The console output shows:
      "C:\Users\user\Documents\AutoIT\Scripts\WSI Tools.au3" (197) : ==> Variable must be of type "Object".: For $i In $ipaddress For $i In $ipaddress^ ERROR ->14:12:16 AutoIt3.exe ended.rc:1 +>14:12:16 AutoIt3Wrapper Finished. >Exit code: 1 Time: 9.811
    • Skyrimfus
      By Skyrimfus
      Hello. I don't know why but when I use
      TCPSend($TCPconnect,"0x427938BB8D7AC6EDD96CE6A39603B3233FDBED9C2B67CCF9BEC146531B3F2FF25C70EBAC402DFD5738CD7CBEE643970BB20F9BBC08") Sometimes the server gets the full payload (0x427938BB8D7AC6EDD96CE6A39603B3233FDBED9C2B67CCF9BEC146531B3F2FF25C70EBAC402DFD5738CD7CBEE643970BB20F9BBC08)
      But sometimes it "trims" it by 2 (0x7938BB8D7AC6EDD96CE6A39603B3233FDBED9C2B67CCF9BEC146531B3F2FF25C70EBAC402DFD5738CD7CBEE643970BB20F9BBC08)
      Anybody knows the reason?
       
      EDIT: As i was writing this too late and now that I read this I realise that it sounds confusing so let me explain more
      The client takes 2 inputs Username and Password and it formats it like so: {login}Username{next}Password{Next}1{Next}RandomNumber{endl}
      And sends the formated string using TCPsend() to the server
       
      TCPSend($TCPconnect,"{login}"&$username&"{next}"&$password&"{next}"&$boolean&"{next}"&$rnumber&"{endl}") And on the server side, it uses:
      While 1 $recv = TCPRecv($sckt,2048) If $recv <> "" Then _print($recv) Endif Wend The TCPsend should match TCPrecv data, right?
      Well the problem is that sometimes the data recieved is right, and sometimes it is wrong.
       
      Example of good transfer:

      Example of bad transfer:

×