Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X
X


Photo

FF.au3 (V0.6.0.1b-10)


  • Please log in to reply
639 replies to this topic

#621 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 29 September 2014 - 05:48 PM

Post your code, please.

The problem with the private Window I have resolved.

 

But the function _FFWindowOpen still doesn't returns the Handle of the opened window. Just 0x000000

#include "FF.au3" _FFConnect(default,Default,6000) _FFWindowOpen("http://www.youtube.com", True, True)

Edited by Rickname, 29 September 2014 - 05:53 PM.








#622 Danp2

Danp2

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 926 posts

Posted 29 September 2014 - 05:51 PM

How are you checking?

 

According to the function header for _FFWindowOpen, @Extended is supposed to hold the window handle.


Edited by Danp2, 29 September 2014 - 05:52 PM.


#623 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 29 September 2014 - 05:53 PM

Return Value ..: Success      - 1 and sets ;                  @EXTENDED    - Window handle ;                  Failure      - 0 and sets ;                  @ERROR       - ;                  @EXTENDED    - ""

_FFWindowOpen("http://www.youtube.com", True, True) MsgBox(0, "", @extended)

My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#624 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 29 September 2014 - 05:57 PM

Return Value ..: Success      - 1 and sets ;                  @EXTENDED    - Window handle ;                  Failure      - 0 and sets ;                  @ERROR       - ;                  @EXTENDED    - ""
_FFWindowOpen("http://www.youtube.com", True, True) MsgBox(0, "", @extended)

Yes I tested it now and its returning 0 for me but the browser window appears and is working well but it doesn't retrieveing the handle o.O

 

Anyways if its a problem only for me but it works good for the others... I will investigate further...


Edited by Rickname, 30 September 2014 - 08:52 AM.


#625 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 29 September 2014 - 06:04 PM

Yes I tested it now and its returning 0 for me but the browser window appears and is working well but it doesn't retrieveing the handle o.O

 

Anyways if its a problem only for me but it works good for the others... I will investigate further...

 

Hm. See if you can get the handle to the window after the fact with _FFWindowGetHandle().


My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#626 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 29 September 2014 - 06:16 PM

Hm. See if you can get the handle to the window after the fact with _FFWindowGetHandle().

I have tried, it works but if I start the window hidden or without being activated, it results in 0

 

Im wondering if you have the same problem. Have you tried it ? Is it showing in the Console the handle of the opened window ?


Edited by Rickname, 29 September 2014 - 06:18 PM.


#627 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 29 September 2014 - 06:32 PM

Try using _FFStart(), I am not at the office and am on a small net book. I will give this a try when I get back to the office ;)

_FFStart([$sURL = "about:blank"[, $sProfile = "default"[, $iMode = 1[, $bHide = False[, $IP = "127.0.0.1"[, $iPort = 4242]]]]]])

My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#628 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 29 September 2014 - 06:48 PM

Well _FFStart returns only the PID of the process who has the new window. I can do a thing to find the handle by listing all the associated windows of the process by PID, but Im not sure if this will work when the window is started hidden...

 

Good luck at your office tho ;)


Edited by Rickname, 30 September 2014 - 08:52 AM.


#629 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 30 September 2014 - 01:35 PM

Well _FFStart returns only the PID of the process who has the new window. I can do a thing to find the handle by listing all the associated windows of the process by PID, but Im not sure if this will work when the window is started hidden...

 

Good luck at your office tho ;)

 

Same result as you got in @extended. Successfully navigated to the page, but no window handle for @extended

Return Value ..: Success      - 1 and sets ;                  @EXTENDED    - Window handle

Not sure if it is my lack of knowledge for FF functions, but it seems like it is not correctly setting the window handle in the return value for _FFWindowOpen().


  • Rickname likes this

My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#630 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 30 September 2014 - 02:10 PM

Same result as you got in @extended. Successfully navigated to the page, but no window handle for @extended

Return Value ..: Success      - 1 and sets ;                  @EXTENDED    - Window handle

Not sure if it is my lack of knowledge for FF functions, but it seems like it is not correctly setting the window handle in the return value for _FFWindowOpen().

Exactly. I had this problem like since long time ago, and I see noone fixed it >.< I will try to fix the function myself and post it here if I resolve something...



#631 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 30 September 2014 - 02:14 PM

Exactly. I had this problem like since long time ago, and I see noone fixed it >.< I will try to fix the function myself and post it here if I resolve something...

 

I will look into it as well, but do not have extensive experience so I doubt I will be the one to fix it :)

 

Good luck ;)


My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#632 AutoFan

AutoFan

    Seeker

  • Normal Members
  • 9 posts

Posted 02 October 2014 - 07:44 PM

Can I disable/enable/install/remove addon using FF.au3 UDF ?


Edited by AutoFan, 02 October 2014 - 07:44 PM.


#633 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 03 October 2014 - 07:54 PM

Can I disable/enable/install/remove addon using FF.au3 UDF ?

 

Theres no special function in the UDF to do this, but I think you can command Firefox to do this via the _FFCmd() function. But since I don't know Javascript language, I don't know whats the command to make the browser to disable/enable/install/remove the addon. Sure someone will know !



#634 david678

david678

    Seeker

  • Normal Members
  • 1 posts

Posted 16 October 2014 - 05:22 AM

Does there any method to add/modify cookies in Firefox via FF.au3?

Thanks!



#635 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 21 October 2014 - 01:53 PM

Does anybody knows what this function does ?? :

 

__FFSetTopDocument()

 

I have seen it appearing many times in the FF.au3 UDF >.< and has no visual effect when run !


Edited by Rickname, 21 October 2014 - 02:13 PM.


#636 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted 21 October 2014 - 02:55 PM

Does there any method to add/modify cookies in Firefox via FF.au3?

Thanks!

Have a look: link

 

Does anybody knows what this function does ?? :

 

__FFSetTopDocument()

 

I have seen it appearing many times in the FF.au3 UDF >.< and has no visual effect when run !

 

That's because:

Internal function __FFSetTopDocument()

as you can see it is an internal function.


My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#637 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted 21 October 2014 - 03:22 PM

Have a look: link

 

 

That's because:

Internal function __FFSetTopDocument()

as you can see it is an internal function.

Hey, thanks for replying :)

 

I saw it is an internal function, but I dont understand what it does more exactly, why is it needed there ? For example in the _FFLoadWait function :

AutoIt         
Func _FFLoadWait($iTimeOut = $_FF_LOADWAIT_TIMEOUT, $bStop = $_FF_LOADWAIT_STOP)     Local Const $sFuncName = "_FFLoadWait"     Local $iLoadingTime = 0     If $iTimeOut < 1000 Then $iTimeOut = 1000     Local $bTrace = $_FF_COM_TRACE     $_FF_COM_TRACE = False     If Not $_FF_COM_TRACE Then ConsoleWrite("_FFLoadWait: ")     Local $TimeOutTimer = TimerInit()     While TimerDiff($TimeOutTimer) < $iTimeOut         If Not $_FF_COM_TRACE Then ConsoleWrite(".")         If _FFCmd("FFau3.tmp=window.getBrowser().webProgress;FFau3.tmp.isLoadingDocument && FFau3.tmp.busyFlags ? false: true;") Then             $iLoadingTime = Round(TimerDiff($TimeOutTimer))             ConsoleWrite(" loaded in " & $iLoadingTime & "ms" & @CRLF)             Sleep($_FF_CON_DELAY * 1.4)             __FFSetTopDocument()             $_FF_COM_TRACE = $bTrace             Return SetError(0, $iLoadingTime - $_FF_CON_DELAY * 1.4, 1)         EndIf         Sleep(250)     WEnd     If $bStop Then _FFAction("stop")     __FFSetTopDocument()     $_FF_COM_TRACE = $bTrace     ConsoleWrite(@CRLF & @CRLF)     Return SetError(__FFError($sFuncName, $_FF_ERROR_Timeout, "Can not check site status."), $iLoadingTime, 0) EndFunc   ;==>_FFLoadWait

Im asking because I import line of code by line of code those functions in my program and I want to be as less complicated, practical, and small as possible, so I want to get rid of those useless calls of this __FFSetTopDocument() function, but Im not sure if is it vital or not >.<

 

Thanks in advance ! :sweating:


Edited by Rickname, 21 October 2014 - 03:23 PM.


#638 MikahS

MikahS

    Humility is attentive patience.

  • Active Members
  • PipPipPipPipPipPip
  • 576 posts

Posted Yesterday, 01:02 PM

Well, have a try with not having those function calls in the function that you would like to use, and see if it still functions as it normally would.

 

But, I think this __FFSetTopDocument() just sets the document at the top of the current page.

  1. Func __FFSetTopDocument()
  2.     $_FF_FRAME = 'top'
  3.     __FFSend("FFau3.WCD=window.content.top.document;")
  4.     Local $sRet = __FFRecv(2000)
  5.     ConsoleWrite($sRet & @CRLF)
  6.     Return
  7. EndFunc   ;==>__FFSetTopDocument

My Snips: graphCPUTemp ~ getENVvars

My Scripts: Short-Order Encrypter ~ AuPad - Notepad written entirely in AutoIt

 

Feel free to use any of my code for your own use. (a comment would be nice though)


#639 Rickname

Rickname

    Adventurer

  • Active Members
  • PipPip
  • 104 posts

Posted Yesterday, 08:41 PM

 

Well, have a try with not having those function calls in the function that you would like to use, and see if it still functions as it normally would.

 

But, I think this __FFSetTopDocument() just sets the document at the top of the current page.

  1. Func __FFSetTopDocument()
  2.     $_FF_FRAME = 'top'
  3.     __FFSend("FFau3.WCD=window.content.top.document;")
  4.     Local $sRet = __FFRecv(2000)
  5.     ConsoleWrite($sRet & @CRLF)
  6.     Return
  7. EndFunc   ;==>__FFSetTopDocument

Yea I have tried the function without calling __FFSetTopDocument and it works with no difference !

 

Also I have tried alone the __FFSetTopDocument function on a visible down-scrolled webpage, and absolutely no effect it has ! It doesn't scroll the page up to the top. Thats why I was asking here about it, since I see its so useless..lol



#640 sjx

sjx

    Seeker

  • Normal Members
  • 5 posts

Posted Today, 03:13 AM

What's the best way to download a file specified by a url using firefox? Is there a FF function similar to InetGet?

 

or

 

a more advanced question, how to parse FF cache so I can retrieve a file that is already in FF cache?

 

 






5 user(s) are reading this topic

0 members, 5 guests, 0 anonymous users