Leaderboard
Popular Content
Showing content with the highest reputation on 01/07/2014 in all areas
-
You're the last person I would call a nuisance, especially with our whole AutoIt.xml issue! The only way you could be a nuisance is if you kept posting Trac Tickets saying "...this is old, that's old, this is ugly" and expecting us (Devs/MVPs) to do all the work. It's a community effort, as such, it's great when the community binds together to improve AutoIt's infrastructure.2 points
-
Drawing Individual Pixels
jaberwacky reacted to iamtheky for a topic
eh, sometimes you get mocked and help, other times just mocked. You will eventually be pleased with any responses at all. Here is a small script that sets pixels on the GUI thrown by progresson. Reading all UEZ's stuff should be requisite when learning to color, would have saved me from writing that.1 point -
string concantenation not working
DatMCEyeBall reacted to guinness for a topic
garysr59, Declare $t before the loop and see how that works out for you.1 point -
Ternary operator clarification ($1 = 0) ? ($b = 0) : ($b = 1)
czardas reacted to DatMCEyeBall for a topic
The "flow" being _Iif()?1 point -
Legnadrak, Easy - just change the background colour of the GUI - this makes it red: Global $hRectangle_GUI = GUICreate("", @DesktopWidth, @DesktopHeight, 0, 0, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST) GUISetBkColor(0xFF0000) ; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Would you like it to be draggable and resizable as well? If so then this might be of interest: #include <GuiConstantsEx.au3> #include <WindowsConstants.au3> #Include <ScreenCapture.au3> Global $hCapture_GUI ; Set distance from edge of Capture_GUI where resizing is possible Global Const $iMargin = 4 ; Set max and min Capture_GUI sizes Global Const $iGUIMinX = 50, $iGUIMinY = 50, $iGUIMaxX = @DesktopWidth - 100, $iGUIMaxY = @DesktopHeight - 100 _Main() Func _Main() Local $sBMP_Path = @ScriptDir & "\Rect.bmp" ; Create GUI Local $hMain_GUI = GUICreate("Select Rectangle", 240, 50) Local $hRect_Button = GUICtrlCreateButton("Mark Area", 10, 10, 80, 30) Local $hCancel_Button = GUICtrlCreateButton("Cancel", 150, 10, 80, 30) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $hCancel_Button FileDelete($sBMP_Path) Exit Case $hRect_Button GUISetState(@SW_HIDE, $hMain_GUI) Local $aCoords = Mark_Rect() ; Capture selected area _ScreenCapture_Capture($sBMP_Path, $aCoords[0], $aCoords[1], $aCoords[0] + $aCoords[2], $aCoords[1] + $aCoords[3], False) GUISetState(@SW_SHOW, $hMain_GUI) ; Display image Local $hBitmap_GUI = GUICreate("Selected Rectangle", $aCoords[2], $aCoords[3], 100, 100) Local $hPic = GUICtrlCreatePic(@ScriptDir & "\Rect.bmp", 0, 0, $aCoords[2], $aCoords[3]) GUISetState() EndSwitch WEnd EndFunc ;==>_Main ; ------------- Func Mark_Rect() ; Create capture GUI $hCapture_GUI = GUICreate("Y", 100, 100, -1, -1, $WS_POPUP, BitOR($WS_EX_LAYERED, $WS_EX_TOPMOST)) GUISetBkColor(0xABCDEF) ; Create label for dragging Local $cLabel = GUICtrlCreateLabel("", $iMargin * 2, $iMargin * 2, 100 - ($iMargin * 4), 100 - ($iMargin * 4), -1, $GUI_WS_EX_PARENTDRAG) GUICtrlSetBkColor(-1, 0xFFFFFF) GUICtrlSetResizing(-1, $GUI_DOCKBORDERS) ; Create context menu Local $cContextMenu = GUICtrlCreateContextMenu($cLabel) $cContext_Capture = GUICtrlCreateMenuItem("Capture", $cContextMenu) $cContext_Cancel = GUICtrlCreateMenuItem("Cancel", $cContextMenu) ; Hide GUI _WinAPI_SetLayeredWindowAttributes($hCapture_GUI, 0xABCDEF, 250) GUISetState() ; Set transparency level WinSetTrans($hCapture_GUI, "", 100) ; Register message handlers GUIRegisterMsg($WM_MOUSEMOVE, "_SetCursor") ; For cursor type change GUIRegisterMsg($WM_LBUTTONDOWN, "_WM_LBUTTONDOWN") ; For resize/drag GUIRegisterMsg($WM_GETMINMAXINFO, "_WM_GETMINMAXINFO") ; For GUI size limits While 1 Switch GUIGetMsg() Case $cContext_Capture ; Get GUI position and delete $aPos = WinGetPos($hCapture_GUI) GUIDelete($hCapture_GUI) ; Unregister message handlers GUIRegisterMsg($WM_MOUSEMOVE, "") GUIRegisterMsg($WM_LBUTTONDOWN, "") GUIRegisterMsg($WM_GETMINMAXINFO, "") ; Peturn position Return $aPos Case $cContext_Cancel Exit EndSwitch WEnd EndFunc ;==>Mark_Rect ; Set cursor to correct resizing form if mouse is over a border Func _SetCursor() Local $iCursorID Switch _Check_Border() Case 0 $iCursorID = 2 Case 1, 2 $iCursorID = 13 Case 3, 6 $iCursorID = 11 Case 5, 7 $iCursorID = 10 Case 4, 8 $iCursorID = 12 EndSwitch GUISetCursor($iCursorID, 1) EndFunc ;==>_SetCursor ; Check cursor type and resize/drag window as required Func _WM_LBUTTONDOWN($hWnd, $iMsg, $wParam, $lParam) Local $iCursorType = _Check_Border() If $iCursorType > 0 Then ; Cursor is set to resizing style so send appropriate resize message $iResizeType = 0xF000 + $iCursorType _SendMessage($hCapture_GUI, $WM_SYSCOMMAND, $iResizeType, 0) EndIf EndFunc ;==>_WM_LBUTTONDOWN ; Determines if mouse cursor over a border Func _Check_Border() Local $aCurInfo = GUIGetCursorInfo($hCapture_GUI) Local $aWinPos = WinGetPos($hCapture_GUI) Local $iSide = 0 Local $iTopBot = 0 If $aCurInfo[0] < $iMargin Then $iSide = 1 If $aCurInfo[0] > $aWinPos[2] - $iMargin Then $iSide = 2 If $aCurInfo[1] < $iMargin Then $iTopBot = 3 If $aCurInfo[1] > $aWinPos[3] - $iMargin Then $iTopBot = 6 Return $iSide + $iTopBot EndFunc ;==>_Check_Border ; Set min and max GUI sizes Func _WM_GETMINMAXINFO($hWnd, $iMsg, $wParam, $lParam) $tMinMaxInfo = DllStructCreate("int;int;int;int;int;int;int;int;int;int", $lParam) DllStructSetData($tMinMaxInfo, 7, $iGUIMinX) DllStructSetData($tMinMaxInfo, 8, $iGUIMinY) DllStructSetData($tMinMaxInfo, 9, $iGUIMaxX) DllStructSetData($tMinMaxInfo, 10, $iGUIMaxY) Return 0 EndFunc ;==>_WM_GETMINMAXINFO Drag with the mouse and put the cursor close to the edge (excellent album that) to resize. Then right click once you have the rectangle where and how you want it. M231 point
-
Ternary operator clarification ($1 = 0) ? ($b = 0) : ($b = 1)
czardas reacted to Richard Robertson for a topic
AutoIt doesn't let you make assignments mid-expression. Assignment can only occur at the statement level, and the ternary (?: for czardas) operator handles expressions, not statements.1 point -
Cursor clock
DatMCEyeBall reacted to guinness for a topic
I would like to think you did it for yourself. If you didn't reference me or that thread then I wouldn't have posted here. Don't wake a sleeping lion!1 point -
Legnadrak, Perhaps this old script of mine will give you some ideas: #include <GuiConstantsEx.au3> #include <WindowsConstants.au3> #Include <ScreenCapture.au3> #Include <Misc.au3> Global $iX1, $iY1, $iX2, $iY2, $aPos, $sMsg, $sBMP_Path ; Create GUI $hMain_GUI = GUICreate("Select Rectangle", 240, 50) $hRect_Button = GUICtrlCreateButton("Mark Area", 10, 10, 80, 30) $hCancel_Button = GUICtrlCreateButton("Cancel", 150, 10, 80, 30) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $hCancel_Button FileDelete(@ScriptDir & "\Rect.bmp") Exit Case $hRect_Button GUISetState(@SW_HIDE, $hMain_GUI) Mark_Rect() ; Capture selected area $sBMP_Path = @ScriptDir & "\Rect.bmp" _ScreenCapture_Capture($sBMP_Path, $iX1, $iY1, $iX2, $iY2, False) GUISetState(@SW_SHOW, $hMain_GUI) ; Display image $hBitmap_GUI = GUICreate("Selected Rectangle", $iX2 - $iX1 + 1, $iY2 - $iY1 + 1, 100, 100) $hPic = GUICtrlCreatePic(@ScriptDir & "\Rect.bmp", 0, 0, $iX2 - $iX1 + 1, $iY2 - $iY1 + 1) GUISetState() EndSwitch WEnd ; ------------- Func Mark_Rect() Local $aMouse_Pos, $hMask, $hMaster_Mask, $iTemp Local $UserDLL = DllOpen("user32.dll") ; Create transparent GUI with Cross cursor $hCross_GUI = GUICreate("Test", @DesktopWidth, @DesktopHeight - 20, 0, 0, $WS_POPUP, $WS_EX_TOPMOST) WinSetTrans($hCross_GUI, "", 8) GUISetState(@SW_SHOW, $hCross_GUI) GUISetCursor(3, 1, $hCross_GUI) Global $hRectangle_GUI = GUICreate("", @DesktopWidth, @DesktopHeight, 0, 0, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST) GUISetBkColor(0x000000) ; Wait until mouse button pressed While Not _IsPressed("01", $UserDLL) Sleep(10) WEnd ; Get first mouse position $aMouse_Pos = MouseGetPos() $iX1 = $aMouse_Pos[0] $iY1 = $aMouse_Pos[1] ; Draw rectangle while mouse button pressed While _IsPressed("01", $UserDLL) $aMouse_Pos = MouseGetPos() $hMaster_Mask = _WinAPI_CreateRectRgn(0, 0, 0, 0) $hMask = _WinAPI_CreateRectRgn($iX1, $aMouse_Pos[1], $aMouse_Pos[0], $aMouse_Pos[1] + 1) ; Bottom of rectangle _WinAPI_CombineRgn($hMaster_Mask, $hMask, $hMaster_Mask, 2) _WinAPI_DeleteObject($hMask) $hMask = _WinAPI_CreateRectRgn($iX1, $iY1, $iX1 + 1, $aMouse_Pos[1]) ; Left of rectangle _WinAPI_CombineRgn($hMaster_Mask, $hMask, $hMaster_Mask, 2) _WinAPI_DeleteObject($hMask) $hMask = _WinAPI_CreateRectRgn($iX1 + 1, $iY1 + 1, $aMouse_Pos[0], $iY1) ; Top of rectangle _WinAPI_CombineRgn($hMaster_Mask, $hMask, $hMaster_Mask, 2) _WinAPI_DeleteObject($hMask) $hMask = _WinAPI_CreateRectRgn($aMouse_Pos[0], $iY1, $aMouse_Pos[0] + 1, $aMouse_Pos[1]) ; Right of rectangle _WinAPI_CombineRgn($hMaster_Mask, $hMask, $hMaster_Mask, 2) _WinAPI_DeleteObject($hMask) ; Set overall region _WinAPI_SetWindowRgn($hRectangle_GUI, $hMaster_Mask) If WinGetState($hRectangle_GUI) < 15 Then GUISetState() Sleep(10) WEnd ; Get second mouse position $iX2 = $aMouse_Pos[0] $iY2 = $aMouse_Pos[1] ; Set in correct order if required If $iX2 < $iX1 Then $iTemp = $iX1 $iX1 = $iX2 $iX2 = $iTemp EndIf If $iY2 < $iY1 Then $iTemp = $iY1 $iY1 = $iY2 $iY2 = $iTemp EndIf GUIDelete($hRectangle_GUI) GUIDelete($hCross_GUI) DllClose($UserDLL) EndFunc ;==>Mark_Rect I used mouse drag to define the rectangle, but the principles are the same. M231 point
-
Or you could try the verifier with a Do Until (file is present)loop. edit: spelling Something like this: Do FileCopy($TMP & "\*.gls", $OutFolder) Until FileExists($OutFolder & "\*.gls") = 11 point
-
Ternary operator - nested
DatMCEyeBall reacted to guinness for a topic
No it is. I saw your post in the Call() vs First Class Object thread after posting that. I agree that nested ternary operators could get a little confusing. It took me 20 seconds to confirm the output was indeed correct. Good job the loop wasn't 30!1 point -
File Name: AutoIt v3.3.11.2 Beta File Submitter: Jon File Submitted: 05 Jan 2014 File Category: Beta 3.3.11.2 (5th January, 2014) (Beta) AutoIt: - Fixed #2316: PowerPoint COM event handler initialization error. - Fixed: FileSelectFolder() uses the parent parameter. - Fixed #2512: ObjName() crash. UDFs: - Added: Example for _WinAPI_SystemParametersInfo(). - Fixed: UBound() default was regarded as $UBOUND_DIMENSIONS (0) and not $UBOUND_ROWS (1). - Fixed: _FileListToArrayRec() array concatenation bug. AutoIt3Help: - Changed: Version number to 1.0.0.6. - Added: Windows activation when already open. Others: - Changed: Help file syntax variable names to a standard naming convention for easier understanding and consitency in the calltip syntax files. Click here to download this file1 point
-
Welcome to the forum! This is a good job for AutoIt. I suggest loading all FTPed csv files into a local SQLite database, which will allow you to perform the merge and comparisons you need easily and reliably in one step. Keeping 100 years of history is no problem. UDFs exist to automate Office Word and Excel. If you decide to get wet with this, you'll find solid help here.1 point
-
shyang, Not too difficult: #include <Array.au3> ; Simulate reading contents.txt into an array with FileReadToArray Global $aLines[] = [ _ "asdfqgaghas", _ "sdfqwert", _ "dfgasdfweg", _ "tom is user_admin-user=12345678 testcenter1", _ "sam is user_admin-user=12341238 testcenter2", _ "markis user_admin-user=56234238 testcenter3" _ ] ; Areate arrays large enough to hold the required data Global $aUserName[UBound($aLines)] Global $aTestCenter[UBound($aLines)] Global $aAfter[UBound($aLines)] ; Create 3 counters Global $iUserName = 0, $iTestCenter = 0, $iAfter = 0 For $i = 0 To UBound($aLines) - 1 ; Read the line $sLine = $aLines[$i] ; Determine what to do with it If StringInStr($sLine, "testcenter") Then ; Add the required data to the relevant arrays $aUserName[$iUserName] = StringRegExpReplace($sLine, "^.*(user_admin-user=\d*).*$", "$1") $aTestCenter[$iTestCenter] = StringRegExpReplace($sLine, "^.*(testcenter\d*)$", "$1") ; Increase the counters $iUserName += 1 $iTestCenter += 1 Else ; Add line to the array $aAfter[$iAfter] = $sLine ; Increase the counter $iAfter += 1 EndIf Next ; Remove unused elements ReDim $aUserName[$iUserName] ReDim $aTestCenter[$iTestCenter] ReDim $aAfter[$iAfter] ; And here is the result ready to be written to file with _FileWriteFromArray _ArrayDisplay($aUserName, "username.txt", Default, 8) _ArrayDisplay($aTestCenter, "testcenter.txt", Default, 8) _ArrayDisplay($aAfter, "after.txt", Default, 8) I hope the comments are clear, but please ask if you have any questions. M231 point
-
I'm surprised nobody is complaining it is taking up to much room on their floppies. visual gag added.1 point
-
saywell (William), I created this the other day, I don't know if it's any use to you >> #AutoIt3Wrapper_Au3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7 #AutoIt3Wrapper_Icon=BinICON_1.ico #AutoIt3Wrapper_Outfile=ExtendedDesktop.exe #AutoIt3Wrapper_UseUpx=Y #AutoIt3Wrapper_Res_Description=ExtendedDesktop. #AutoIt3Wrapper_Res_Fileversion=1.0.0.0 #AutoIt3Wrapper_Res_LegalCopyright=nocopyright #AutoIt3Wrapper_Res_Language=2057 #AutoIt3Wrapper_Run_Obfuscator=Y #Obfuscator_Parameters=/SF /SV /OM /CS=0 /CN=0 #AutoIt3Wrapper_res_requestedExecutionLevel=asInvoker #AutoIt3Wrapper_Outfile_Type=exe #AutoIt3Wrapper_UseX64=N #NoTrayIcon #include <WinAPI.au3> #include <WindowsConstants.au3> _Main() Func _Main() Local $sParameter Switch _WinAPI_GetSystemMetrics($SM_CMONITORS) Case 1 $sParameter = "/extend" Case Else $sParameter = "/internal" EndSwitch Return Run(@SystemDir & "DisplaySwitch.exe " & $sParameter, @SystemDir, @SW_HIDE) EndFunc ;==>_Main1 point
-
stdin and stdout with plink.exe (SOLVED)
Cahkhene25 reacted to JDaus for a topic
I have solved this problem and provide a basic (sort of) script to assist those that have problems with plink.exe (putty.exe) or any other app with STDOUT, STDIN & STDERR Found a post that led me to find the problem HERE ... the problem was @CR ... that simple ... the following things need to be edited to get it to work: rename "plink.exe" to jdsplink.exe (or change the code @ line 124 & 169)Change "somehost.com" (line 124) to your SSH Host addressChange "@SW_MINIMIZE" to "@SW_HIDE" when finished#Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_outfile=testing stdout5.exe #AutoIt3Wrapper_Run_Tidy=y #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** ; JDaus created this script to get around some limitations found while working with putty ; It is posted on the autoitscript.com website in the hope that it will be useful to others ; This script forms the basis of part of the Vnc2Me project (http://sf.net/projects/vnc2me/ ; this script was derived from the following post (among others) ; http://www.autoitscript.com/forum/index.php?s=&showtopic=12828&view=findpost&p=88305 ; A script for AutoIt3. Jon is The Man. ; Script generated by AutoBuilder 0.5 Prototype. CyberSlug rocks. ; Edited with SciTE and Tidy. Go JdeB. #include <GuiConstants.au3> Dim $ourProcess Dim $username Dim $password Dim $loop GUICreate("STDIO Window", 425, 322, (@DesktopWidth - 425) / 2, (@DesktopHeight - 362) / 2, $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS) ; Create a read-only edit control $eOutput = GUICtrlCreateEdit("", 0, 10, 423, 250, BitOR($ES_WANTRETURN, $WS_VSCROLL, $WS_HSCROLL, $ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_READONLY)) ; Ping spawn button $bSSH = GUICtrlCreateButton("SSH", 260, 285, 60, 20) ; Notepad spawn button ;$bNotepad = GuiCtrlCreateButton("Notepad", 180, 285, 60, 20) ; Exit button $bExit = GUICtrlCreateButton("Exit", 340, 285, 60, 20) ; Show the GUI window GUISetState() JDs_debug("Vnc2Me - GUI Starting") ; Loop and update the edit control unitl we hit EOF (and get an error) While 1 ; We assign the process ID of ping to $ourProcess below... If $ourProcess Then ; Calling StdoutRead like this returns the characters waiting to be read $ReadCharsWaiting = StdoutRead($ourProcess, 0, 1) ; Calling StderrRead like this returns the characters waiting to be read If @error = -1 Then JDs_debug("Vnc2Me - STDOUT unable to be read") ; Set $ourProcess to zero so we don't try to read nothing... $ourProcess = 0 MsgBox(0, "App Exited", "Process has exited...") ; ContinueLoop means "don't exit the While loop, just start over without doing anything else" ContinueLoop EndIf $ErrCharsWaiting = StderrRead($ourProcess, 0, 1) ; If there was an error reading, the most likely cause us that the child process has quit... If @error = -1 Then JDs_debug("Vnc2Me - STDERR unable to be read") ; Set $ourProcess to zero so we don't try to read nothing... $ourProcess = 0 MsgBox(0, "App Exited", "Process has exited...") ; ContinueLoop means "don't exit the While loop, just start over without doing anything else" ContinueLoop EndIf ; Since we got here there was no error, but were there characters to be read? If $ReadCharsWaiting Then ; Read all available $currentRead = StdoutRead($ourProcess) $Vnc2MeReadUsername = StringRegExp($currentRead, ".*ogin.*") $Vnc2MeReadPassword = StringRegExp($currentRead, ".*assword.*") If $Vnc2MeReadUsername = 1 Then JDs_debug("Vnc2Me - AUTH - 'login' detected") Vnc2MeUsername() ContinueLoop ElseIf $Vnc2MeReadPassword = 1 Then JDs_debug("Vnc2Me - AUTH - 'password' detected") Vnc2MePassword() ContinueLoop Else ; Add what we read to the editbox GUICtrlSetData($eOutput, $currentRead, 1) JDs_debug("Vnc2Me - STDOUT updates fed to GUI") EndIf Sleep(100) ElseIf $ErrCharsWaiting Then ; Read all available $currentErr = StderrRead($ourProcess) $Vnc2MeErrHostKey = StringRegExp($currentErr, ".*host key is not cached.*") If $Vnc2MeErrHostKey = 1 Then JDs_debug("Vnc2Me - STDERR Host key no cached") Vnc2MeAddHostKey() ; GUICtrlSetData($eOutput, $currentErr, 1) ContinueLoop Else GUICtrlSetData($eOutput, $currentErr, 1) JDs_debug("Vnc2Me - STDERR updates fed to GUI") EndIf EndIf ; => no program output waiting. Else ; => $ourProcess not exist. JDs_debug("Vnc2Me - SSH process not started") Sleep(200) EndIf ; => End $ourProcess ; Get any messages from the GUI $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ; X button on window was clicked JDs_debug("Vnc2Me - GUI exiting (windows closed)") Vnc2MeExit() Case $msg = $bExit ; Exit button was clicked JDs_debug("Vnc2Me - GUI exiting (exit button)") Vnc2MeExit() Case $msg = $bSSH ; SSH button was clicked JDs_debug("Vnc2Me - SSH button pressed") ; Run child process and provide console i/o for it. ; 1 ($STDIN_CHILD) = Provide a handle to the child's STDIN stream ; 2 ($STDOUT_CHILD) = Provide a handle to the child's STDOUT stream ; 4 ($STDERR_CHILD) = Provide a handle to the child's STDERR stream $ourProcess = Run("jdsplink.exe -C -L 25501:127.0.0.1:5500 -R 5500:127.0.0.1:5900 somehost.com -v", @ScriptDir, @SW_MINIMIZE, 7) JDs_debug("Vnc2Me - SSH process started") ; Case $msg = $bNotepad ; JDs_debug("Vnc2Me - Notepad button pressed") ; ; Notepad button was clicked ; Run("notepad.exe", @SystemDir) Case Else ;;; EndSelect WEnd JDs_debug("Vnc2Me - ") Func Vnc2MeUsername($username = "") ;if $username not passed in func call, ask for it. If $username = "" Then $username = InputBox("username", "Enter username") If @error = 1 Then Exit EndIf EndIf ;writes "login" JDs_debug("Vnc2Me - AUTH - Passing username") StdinWrite($ourProcess, $username & " " & @CR) EndFunc ;==>Vnc2MeUsername Func Vnc2MePassword($password = "") ;if $password not passed in func call, ask for it. If $password = "" Then $password = InputBox("password", "Enter password for " & $username, '', '*') If @error = 1 Then Exit EndIf EndIf ;writes "password" JDs_debug("Vnc2Me - AUTH - Passing password") StdinWrite($ourProcess, $password & " " & @CR) EndFunc ;==>Vnc2MePassword Func Vnc2MeAddHostKey() ;Add Host key to knownhosts JDs_debug("Vnc2Me - STDERR found") $msgbox = MsgBox(4, "The host is not cached", "This Host is not known, do you want to add it to known hosts ???") If $msgbox = 6 Then StdinWrite($ourProcess, "y " & @CR) EndIf EndFunc ;==>Vnc2MeAddHostKey Func Vnc2MeExit() GUICtrlSetData($eOutput, @CRLF & "Exiting" & @CRLF, 1) StdinWrite($ourProcess, "exit" & @CR) Sleep(2000) ProcessClose("jdsplink.exe") Exit EndFunc ;==>Vnc2MeExit Func JDs_debug($msg) DllCall("kernel32.dll", "none", "OutputDebugString", "str", $msg) EndFunc ;==>JDs_debugtesting_stdout5.au31 point