AL3X Posted May 4, 2008 Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
ProgAndy Posted May 4, 2008 Share Posted May 4, 2008 Stringbetween returns an ARRAY so: $PercentCompleted = _StringBetween($readstream, ". ", "% ") $PercentCompleted = $PercentCompleted [0] *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 Hi, look at this, please If 1 <= $streamcounterwget Then , isn't it ? Greetz Greenhorn Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
ProgAndy Posted May 4, 2008 Share Posted May 4, 2008 If $VelocidadDeDescarga[0] = 0 Then ?? *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 But it doenst work . Which should I use ? Stdout or Stderr ?Use StdOutRead instead and don't forget While 1 $line = StdoutRead($PID) If @error Then ExitLoop WEnd Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 Try for debugging a func like this expandcollapse popup$sWGetDir = @TempDir $sDestDir = 'C:\Downloads' $urlVideo = 'http://dl.video/watchme.avi' $pidWGet = Run($sWGetDir & '\wget.exe -c -P"' & $sDestDir & '" "' & $urlVideo & '"') $sReadOutput = StreamRead($pidWGet) If $sReadOutput Then $RemainingTime = _StringBetween($readstream, 'K ', 's') GUICtrlSetData($TextoTiempoRestante, $RemainingTime & " sec") $DownloadSpeed = _StringBetween($readstream, '% ', 'K ') GUICtrlSetData($TextoVelocidad, $DownloadSpeed & " Kb/s") $PercentCompleted = _StringBetween($readstream, ". ", "% ") GUICtrlSetData($TextoPorcientoCompletado, $PercentCompleted & "%") GUICtrlSetData($DownloadProgressBar, $PercentCompleted) EndIf Func StreamRead($PID) While True $line = StdoutRead($PID) If @error Then ExitLoop ConsoleWrite('StdoutRead: ' & $line) WEnd While True $line = StderrRead($PID) If @error Then ExitLoop ConsoleWrite('StderrRead: ' & $line) WEnd Return $line EndFunc and look what you get from the stream, I will try it also, but a liitle bit later, today. Maybe at today's evening I can tell you more ... Greetz Greenhorn Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 It doesnt show anything... Could you help me if I send you the entire code and the file's that I'm using ?(I'll release the code when its ready )Yep, do it ... Link to comment Share on other sites More sharing options...
AL3X Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) -- Edited July 2, 2015 by AL3X Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 Oh, I see that I've forgot the most important ... $pidWGet = Run($sWGetDir & '\wget.exe -c -P"' & $sDestDir & '" "' & $urlVideo & '"', $sWGetDir, @SW_SHOW, 6) Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 (edited) Do you have email or something ? :S(Size in total = +/- 3mb)'User' at 'email' dot 'com' Edited May 7, 2008 by Greenhorn Link to comment Share on other sites More sharing options...
Greenhorn Posted May 4, 2008 Share Posted May 4, 2008 OK, I got it You can del it ... I'll come back at evening, now I have to eat alittle bit, my dear ... C' ya Greetz Link to comment Share on other sites More sharing options...
MrChiliCheese Posted September 29, 2008 Share Posted September 29, 2008 Hey, i have the same problem at the moment... i'm using StdoutRead(), but the text is een only in the textbox from scite... how can i read this text out? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now