Leaderboard
Popular Content
Showing content with the highest reputation on 03/11/2019 in all areas
-
Write last line of log file that is updating
Earthshine and one other reacted to Nine for a topic
lol, there will always be someone who is giving fishes...2 points -
You only need to do this with a script that is 32-bit on a 64-bit system. Try adding the following to your If statement. If @OSVersion = "WIN_10" And @OSArch = "X64" And Not @AutoItX64 Then Adam1 point
-
Are there any way to get an array of pixelcolour almost instantly?
FrancescoDiMuro reacted to InnI for a topic
#include <ScreenCapture.au3> $hBitmap = _ScreenCapture_Capture() Global $tSize = _WinAPI_GetBitmapDimension($hBitmap), _ $iWidth = $tSize.X, $iHeight = $tSize.Y, $iIndex, _ $iSize = $iWidth * $iHeight, $aPixels[$iHeight][$iWidth], _ $tBits = DllStructCreate("dword[" & $iSize & "]") _WinAPI_GetBitmapBits($hBitmap, 4 * $iSize, DllStructGetPtr($tBits)) _WinAPI_DeleteObject($hBitmap) For $i = 0 To $iHeight - 1 For $j = 0 To $iWidth - 1 $iIndex += 1 $aPixels[$i][$j] = DllStructGetData($tBits, 1, $iIndex) Next Next ;~ #include <Array.au3> ;~ _ArrayDisplay($aPixels)1 point -
On a 64 bit OS running a 32 bit process, redirection sets the system folder as SysWOW64. If you want to access the System32, you can use _WinAPI_Wow64EnableWow64FsRedirection (False) function. Normally, you want to do that because the SysWOW64 DLL is missing or does not work properly. So you should use it on very exceptional situations, not all the time...1 point
-
PixelSearch Problem or glitch?
FrancescoDiMuro reacted to JLogan3o13 for a topic
How many times, exactly, do you need to be personally reminded to stay out of a thread in which a Mod is working? Do you really believe your little comments add anything to the discussion? Edit: When your next comment leads to a vacation from the forum, we'll see if your response is the same1 point -
Modify Windows Contextmenu - (Moved)
nacerbaaziz reacted to AndroidZero for a topic
1 point -
I believe, all your questions is answered in MSDN. Look at This !1 point
-
Modify Windows Contextmenu - (Moved)
nacerbaaziz reacted to AndroidZero for a topic
@Skeletor Thank you for this nice idea it's really out of the box never thought about this. Well it wasn't exactly what I wanted but this helps me in another project !! very cool @nacerbaaziz Awww thanks thats what I was searching for !!! You made my day love this community !1 point -
Those are "only" available in the Full SciTE4AutoIt3 version! Jos1 point
-
While 1 Sleep (1000) $TreeTime -= 4 $Total += 3 GUICtrlSetData($info, $Total & " " & $TreeTime) ; first cell 70 width WEnd So, what I did was added the & and also you can see I made a "space" so it will show like this: "3 4" instead of "34"1 point
-
Make a loop run from 1 to 100 and wait for 10 first commands done then continue.
Skeletor reacted to Earthshine for a topic
Use a For loop. See the help file1 point -
1 point
-
Try this : #include <ScreenCapture.au3> #include <GDIPlus.au3> #include <Date.au3> #include <Memory.au3> Global $RaportFileName = @YEAR & "-" & @MON & "-" & @MDAY & "_" & @HOUR & "_" & @MIN & "_" & @SEC & ".html" $text = "This is first line text" & @CRLF &"and this is next line" _Raport($text, 1) FileWrite(@ScriptDir & "\" & $RaportFileName, "</pre></html>") ; #FUNCTION# ==================================================================================================================== ; Name ..........: _Raport ; Description ...: ; Syntax ........: _Raport($sText1[, $Screen = 0]) ; Parameters ....: $sText1 - a string value. ; $Screen - [optional] an unknown value. Default is 0. ; 0 - Default - do not screenshot ; 1 - added screenshot full desktop ; Return values .: None ; Author ........: Your Name ; Modified ......: ; Remarks .......: ; Related .......: ; Link ..........: ; Example .......: No ; =============================================================================================================================== Func _Raport($sText1, $Screen=0) Local $sText = "" Local $sHead = "" ; Define HTML file header and style $sHead = '<html>' & @CRLF & '<head><meta charset="utf-8"></head>' & @CRLF $sHead = $sHead & '<style>img{border:3px solid #FF0000;}</style>' & @CRLF $sHead = $sHead & '<style>pre{font-family: monospace;}</style>' & @CRLF $sHead = $sHead & '<style>pre{font-size: large;}</style>' & @CRLF $sHead = $sHead & '<pre>' & @CRLF If NOT FileExists(@ScriptDir & "\" & $RaportFileName) Then ; If file Raport not exist then create FileOpen(@ScriptDir & "\" & $RaportFileName, 258) FileWrite(@ScriptDir & "\" & $RaportFileName, $sHead) EndIf If StringInStr($sText1, @CRLF) > 0 Then ; @CRLF (ENTER) change the @CRLF and 11 space (indentation on width "[GG:MM:SS] ") $sText1 = StringReplace($sText1, @CRLF, @CRLF & ' ') EndIf $sText = $sText & $sText1 If $Screen <> 0 Then Local $hBitMap = _ScreenCapture_Capture("") _GDIPlus_Startup() Local $hImage = _GDIPlus_BitmapCreateFromHBITMAP ($hBitMap) Local $bString = Image2BinaryString($hImage) $sText = $sText & @CRLF & '<br> ' & '<img src="data:image/png;base64,' & _ _ConvertToBase64($bString) & '"/>' _GDIPlus_ImageDispose($hImage) _WinAPI_DeleteObject($hBitMap) _GDIPlus_Shutdown() EndIf FileWrite(@ScriptDir & "\" & $RaportFileName, "[" & _NowTime(5) & "] " & $sText & "<br><br>"&@CRLF) ; write to file Raport EndFunc Func _ConvertToBase64($bString) $objXML=ObjCreate("MSXML2.DOMDocument") $objNode=$objXML.createElement("b64") $objNode.dataType="bin.base64" $objNode.nodeTypedValue=Binary($bString) Return $objNode.Text EndFunc Func Image2BinaryString($hBitmap) ; based on UEZ code Local $sImgCLSID, $tGUID, $tParams, $tData $sImgCLSID = _GDIPlus_EncodersGetCLSID("PNG") $tGUID = _WinAPI_GUIDFromString($sImgCLSID) Local $hStream = _WinAPI_CreateStreamOnHGlobal() _GDIPlus_ImageSaveToStream($hBitmap, $hStream, DllStructGetPtr($tGUID)) Local $hMemory = _WinAPI_GetHGlobalFromStream($hStream) Local $iMemSize = _MemGlobalSize($hMemory) Local $pMem = _MemGlobalLock($hMemory) $tData = DllStructCreate("byte[" & $iMemSize & "]", $pMem) Local $bData = DllStructGetData($tData, 1) _WinAPI_ReleaseStream($hStream) _MemGlobalFree($hMemory) Return $bData EndFunc1 point
-
Try with this: $sCommand = "echo y | plink -ssh -pw root root@" & $IPaddress & " exit" RunWait(@ComSpec & " /C " & $sCommand) Hi!1 point