UDF to control FireFox via MozRepl:
Original thread: http://www.autoitscript.com/forum/topic/95595-ffau3-v0601b-10/
I have had several people ask for this, so I decided to work the algorithm for it and this is the result.
What is it?
A Gateway Proxy Sends and Receives Data Unmodified.
What is it used for?
You can use it as a gateway, relay or router between two known static IP addresses.
More information is in the header of the script.
You will need WSA_NBTCP.au3 from here:
If you have any questions or problems, let me know.
This script is based on algorithm code from EnrMa.
Updated: January 22, 2018
Made improvements. Changes are in the script header.
Known Issues: AutoIt x64 does not work properly with this script.
WSA_NBTCP.au3 (Windows Sockets API - Non-Blocking Transmission Control Protocol)
This is an accumulation of WSA code from many sources and modified to suit myself.
These functions have been thoroughly tested using a Local Proxy Server, which
is about the most strenuous test you can use.
Includes my rendition of how a TCPRecv Timeout should work. Also includes a
timewait/timeout using Select for TCP Send, which works great for that function.
You will need a loop to use _WSA_TCPRecv(). An example will be forthcoming in a second post.
- AutoIt Versions: 184.108.40.206 thru 220.127.116.11 (32Bit only).
- TCPStartup() at beginning of script on startup.
- TCPShutDown() and _WSA_Cleanup() on exit.
Download UDF: WSA_NBTCP.au3
I have a problem trying to use _IEAttach to recover control after a Windows Explorer reset (e.g. on Windows 7), since all the
InternetExplorer.Application objects appear to be destroyed by this event. An example of this is when a PC has some kind of fault causing a pop-up error message "Windows Explorer has stopped working". I can simulate this event by using Windows Task Manager to end the Explorer.exe process then to file, new task (run...) Explorer.exe
After this event, _IEAttach gives an @error of:
7 ($_IEStatus_NoMatch) - No Match
However, using WinList() followed by WinGetText() I can recover the URL for an IE session that has lost its
InternetExplorer.Application object which could be used to _IECreate a new session (the $iTryAttach fails) and WinKill() the original session but the result is a if a refresh had been done (any form entries are lost) . Unfortunately form entries do not appear as text or hidden text to Windows so I'm looking for the best way to read the contents of an Internet Explorer screen (even if just text without structure).
When there is no InternetExplorer.Application object (because of some Windows fault) but still with an Internet Explorer session running, I tried to read its contents by a "Select All" & "Copy to Clipboard" but its form entries are blanked and combo boxes choices are all displayed with no way of finding out which ones were selected.
Local $ClipBoardSave = _ClipBoard_GetData() ;not ClipGet() which is text only ClipPut("") ;Clear User's Clipboard Local $sText = "" Local $hWnd = WinActivate("Window Title", "") If IsHWnd($hWnd) Then Local $bStatusCtrlSend = ControlSend("Window Title", "", "", "^a^c") If $bStatusCtrlSend Then Local $bStatusCtrlClick = ControlClick("Window Title", "", "") If $bStatusCtrlClick Then $sText = ClipGet() _ClipBoard_SetData($ClipBoardSave) ;not ClipPut($ClipBoardSave) which is text only
Is there a solution to this please?