Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/06/2013 in all areas

  1. This UDF has been rewritten - the new version can be found here. ---------------------------------------------------------------------------------------------- [New version] - 28 Aug 16 Added: The UDF is now RTL sensitive. Thanks to shai for the request. New UDF and examples below. Details of previous versions: The GUIExtender UDF allows you to have multiple sections within your GUIs which can be either static or extendable. The extendable sections can be extended and retracted either by UDF created buttons or programmatically by other controls or HotKeys. The controls on the sections are fully functional and there is no overlap problem when retracted (see the details section if you want to know how). The UDF can be used in both MessageLoop and OnEvent modes and with both native and UDF created controls, as well as embedded objects and child GUIs. Details of how the UDF works for those who are interested: The UDF and plenty of commented examples are in the attached zip: As always, happy to receive brickbats or bouquets. M23
    1 point
  2. I just wanted to post a THANK YOU to everyone that is, and has in the past, developing the AutoIT suite and supporting software. Also, a THANK YOU to everyone on the forum who helps when people need assistance. Answers are usually prompt, and not too cryptic, to questions posted. And I actually appreciate the assistance that comes in the form of "you might want to look up ______", rather than always just tossing out the answer right there. That helps amateur developers learn more about the language and tools. Though you may not always get a "thanks" when you provide help, I hope you know that you are appreciated by many.
    1 point
  3. EddCase, What are you expecting to happen with this line: If @error = 1 Then MsgBox (0, "VideoLan", "VLC is not installed, please install and rerun") & ShellExecute ("http://www.videolan.org/index.html")Because it make no sense at all at present. Do you want a MsgBox and then a browser opening? If that is the case then: If @error = 1 Then $reg = RegRead ( "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\VideoLAN\VLC\", "" ) If @error = 1 Then MsgBox (0, "VideoLan", "VLC is not installed, please install and rerun") ShellExecute ("http://www.videolan.org/index.html") EndIf EndIfmight be a better bet. M23
    1 point
  4. KaFu

    Web Screenshot

    Example in still contained some AutoItObject leftovers, here's a more cleaned up version. #include <IE.au3> #include <WinAPI.au3> #include <ScreenCapture.au3> #include <WindowsConstants.au3> ; Runs fine with Beta 3.3.9.5+ If Int(StringReplace(@AutoItVersion, ".", "")) <= 3381 Then MsgBox(0, "Exit", "Requires AutoIt version > 3.3.8.1, try with Beta") Exit EndIf _WebCaptureTest("http://funk.eu", "Test1.png") Func _WebCaptureTest($Url, $ImageName) Local $hBmp = _WebCapture($Url, 1280) _ScreenCapture_SaveImage($ImageName, $hBmp, True) EndFunc ;==>_WebCaptureTest Func _WebCapture($Url, $WebWidth = 1024) Local $oIE = ObjCreate("Shell.Explorer.2") Local $hGUI = GUICreate("", $WebWidth, 768, -1, -1) Local $cObj = GUICtrlCreateObj($oIE, 0, 0, $WebWidth, 768) _IELoadWaitTimeout(20000) ; 20 sec _IENavigate($oIE, $Url) _IELoadWait($oIE) Local $oDocument = $oIE.document Local $oBody = $oIE.document.body Local $oHtml = $oIE.document.documentElement $oBody.scroll = "no" $oBody.style.borderStyle = "none" $oHtml.style.overflow = 'hidden' $oBody.style.overflow = 'hidden' Local $oIViewObject2 = ObjCreateInterface($oDocument, "{00000127-0000-0000-C000-000000000046}", "Draw hresult(dword;long;ptr;ptr;dword;dword;ptr;ptr;int;dword);") If @error Then Return SetError(1, 0, 0) Local $BodyWidth = $oBody.scrollWidth Local $BodyHeight = $oBody.scrollHeight Local $RootWidth = $oHtml.scrollWidth Local $RootHeight = $oHtml.scrollHeight Local $Width = $BodyWidth Local $Height = $RootHeight If $BodyHeight > $Height Then $Height = $BodyHeight $oIE.width = $Width $oIE.height = $Height Local $hDC = _WinAPI_GetDC(0) Local $hMemDC = _WinAPI_CreateCompatibleDC($hDC) Local $hBmp = _WinAPI_CreateCompatibleBitmap($hDC, $Width, $Height) _WinAPI_SelectObject($hMemDC, $hBmp) Local $sRECT = DllStructCreate($tagRECT) DllStructSetData($sRECT, "Top", 0) DllStructSetData($sRECT, "Left", 0) DllStructSetData($sRECT, "Right", $Width) DllStructSetData($sRECT, "Bottom", $Height) Local Const $DVASPECT_CONTENT = 1 $oIViewObject2.Draw($DVASPECT_CONTENT, -1, 0, 0, Number($hDC), Number($hMemDC), Number(DllStructGetPtr($sRECT)), 0, 0, 0) _WinAPI_DeleteDC($hMemDC) _WinAPI_ReleaseDC(0, $hDC) GUICtrlDelete($cObj) GUIDelete($hGUI) $oIViewObject2 = 0 $oIE = 0 Return $hBmp EndFunc ;==>_WebCapture
    1 point
  5. Kinda wonder why some are textually pre-specifying a variable scoop on a variable when is not declared yet. Beginners tip: Use: #AutoIt3Wrapper_AU3Check_Parameters=-q -d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7 Les ambiguity in what you should not do. (less danger in learning bad habits.) ... Proof: Tricky proposition. ...
    1 point
  6. I see, there's nothing wrong with what you are using unless you want to open the webpage in a browser other than your default, and you don't mind it opening in another window/instance.
    1 point
  7. updated 1st post with all working examples under W7 - 64 bits. Added more debugging lines so investigating based on hexfiles can be done if no match is found or why its unclear that there is no match. Added a small threshold to have a match of 97% of the bits/bytes on a line. (small risk of false positives) which seems to be a workaround for weird situation that calculator finding gives a false. Investigating the false on calculator.bmp showed in the debugfiles that actually windows/GDI is indeed making calculator.bmp bits different compared to the same bits in a full screen where calculator is shown.
    1 point
  8. Thanks Hope it helped And hope it helps others as well, I decided to drop this since I no long have a need for it and I'm moving on to c++ edit: Added the latest *updates* it is unfinished. but it has some nice features. Includes remote screenshot and the start of a chatbox. ClientExample.au3 Server.au3
    1 point
  9. ripdad

    TCP_Connections

    I needed something a little better to help automate a hosts file. This Example Script is missing that automation, but it does provide the foundation for it. If it helps you, then great! Credits are given inside the script. TCP_Connections.au3
    1 point
×
×
  • Create New...