Jump to content
Sign in to follow this  
Bowmore

AutoIt3Wrapper issue with Console write in Scite4AutoIt3

Recommended Posts

Bowmore

AutoIt3Wrapper v.1.10.1.8

I like to use a slightly different versioning scheme to the standard one supplied by Jos in AutoIt3Wrapper as some my applications need to be updated frequently sometimes several times a day and I like to keep copies of all previous builds. The scheme i use is <Major Version>.<Minor Version>.<Build Day No>.<Build Revision>.

These wrapper directives give me an archive of every build

#AutoIt3Wrapper_Run_Before=MKDIR "%scriptdir%\Release"
#AutoIt3Wrapper_Run_Before=copy "%in%" "%scriptdir%\Release\%scriptfile%.%fileversion%.au3"
#AutoIt3Wrapper_Run_After=copy "%out%" "%scriptdir%\Release\%scriptfile%.%fileversion%.exe"
#AutoIt3Wrapper_Run_After=copy "%out%" "%scriptdir%\ReleaseoÝ÷ Ù:r½ëaÂ'¢¹£ºËkzZqåZ'EWz»"¢|"¶²b~'½êììyæÞÚÞr©WºÚ·u«j^­8b²Ø¦y©m .qǬ±û¥*Þr©Wëh"ÝÖ­ªiz¼"¶{  ¢Ü©àzË.r¬­êeiȧIâr^Â+aëh"Õ'Êy©ÝÐ.¶-ÝjÚ¦«Âä°*'²^Z¸­yÚ²z-¢ëiºÖ§ÊØb§¶¢{(ì"Ú0¡û×Ê»p¡yÉ¡ë'¢Ú.¶­j|zÖ¢ë(}ê뢻¢éÝ¢yr¶
)ÝÆ­x"«)à²Þ®º+³«yú.Ò7ög.®*.±«-£rë-­ç(¥x0ØméZµë-½êìè|­ wÛ]´².׺ǭ+ºÚ"µÍ[È[YÑ[UÚ[Û  ÌÍÚWÑ[UÚ[ÛBSØØ[ ÌÍÕÓ[XÈHÝ[ÔÜ]
    ÌÍÚWÑ[UÚ[Û    ][ÝË][ÝÊBRY ÌÍÕÓ[XÖÌH ÝÈ
[BPÛÛÛÛUÜ]J    ][ÝËHÈ[[Y[UÚ[Û][ÝÈ   [È ÌÍÚWÑ[UÚ[Û    [È ][ÝËÛÛZ[È[ÜH[
[XËÚ[ÙYÎ][ÝÈ  [È ÌÍÐUUVWÔÓWÕT  [ÈÔBBT]   ÌÍÐUUVWÔÓWÕTQ[YNÂRY  ÌÍÕÓ[XÖÌH È
[Q[H    ÌÍÕÓ[XÖÍWBQÜ ÌÍÞHHÈ
BRY ÌÍÕÓ[XÖÉÌÍÞHH  ÌÎNÉÌÎNÈ[ ÌÍÕÓ[XÖÉÌÍÞHHBRYÝ
    ÌÍÕÓ[XÖÉÌÍÞHOH[X   ÌÍÕÓ[XÖÉÌÍÞJJH[BBPÛÛÛÛUÜ]J    ][ÝÉÌÌÎÈ[[Y[UÚ[Û[YH ][ÝÈ  [È ÌÍÞ  [È ][ÝÏI][ÝÈ   [È ÌÍÕÓ[XÖÉÌÍÞH   [È ][ÝË]Ú[HÚ[ÙYÎ][ÝÈ   [È[X   ÌÍÕÓ[XÖÉÌÍÞJH  [ÈÔBBBIÌÍÕÓ[XÖÉÌÍÞHH[X   ÌÍÕÓ[XÖÉÌÍÞJBBQ[YS^BNÐÝÝÛH[ÛÛÙBNÉÓXZÜÚ[ÛÝËÓZ[ÜÚ[ÛÝËÐZ[^HÉÝËÐZ[]Ú[ÛÝÂNÓXZÙHÈZ[^H[
Z[Û]^BSØØ[   ÌÍÑ^ÈHÑ]QY ÌÎNÑ ÌÎNË ][ÝÌÌKÌH    ][ÝËÓÝÐØ[Ê
JBRY    ÌÍÕÓ[XÖÌ×H   ÉÝÈ  ÌÍÑ^È[BIÌÍÕÓ[XÖÌ×HH  ÌÍÑ^ÂBIÌÍÕÓ[XÖÍHHLBQ[YNÈ]]È[Ü[Y[Ú[]YÝYRY ÌÍÒSÑ[]Ú[ÛÐ]]Ò[Ü[Y[    ÉÝÈ  ][ÝÛ][ÝÈ[BIÌÍÒSÑ[]Ú[ÛÓ]ÈH   ÌÍÕÓ[XÖÌWH    [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÌH
ÈH [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÌ×H   [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÍH
ÈBQ[ÙBBNÈ[Ø^È]HHÝ[[Y[ÂBIÌÍÒSÑ[]Ú[ÛÓ]ÈH   ÌÍÕÓ[XÖÌWH    [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÌH [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÌ×H   [È ][ÝË][ÝÈ    [È ÌÍÕÓ[XÖÍH
ÈBQ[YT]    ÌÍÒSÑ[]Ú[ÛÓ]Â[[ÈÏOIÝÕ[YÑ[UÚ[Û

"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

Share this post


Link to post
Share on other sites
Jos

I have only started a few days ago looking at making the supplied script in SciTE4AutoIt3 compatible with the latest production version and I did see that the Func I use to collect the STDOUT and STDERR didn't work anymore.

No guarantees but try this version of the func in AutoIt32Wrapper.

;
Func ShowStdOutErr($l_Handle, $ShowConsole = 1)
    Local $Line, $nbrChar1, $nbrChar2, $tot_out
    While 1
        Sleep(10)
        $nbrChar1 = StdoutRead($l_Handle, True)
        If $nbrChar1 Then
            $Line = StdoutRead($l_Handle)
            $tot_out &= $Line
            If $ShowConsole Then ConsoleWrite($Line)
        EndIf
        $nbrChar2 = StderrRead($l_Handle, True)
        If @error Then ExitLoop
        If $nbrChar2 Then
            $Line = StderrRead($l_Handle)
            If @error Then ExitLoop
            $tot_out &= $Line
            If $ShowConsole Then ConsoleWrite($Line)
        EndIf
    WEnd
    Return $tot_out
EndFunc;==>ShowStdOutErr

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
Bowmore

I have only started a few days ago looking at making the supplied script in SciTE4AutoIt3 compatible with the latest production version and I did see that the Func I use to collect the STDOUT and STDERR didn't work anymore.

No guarantees but try this version of the func in AutoIt32Wrapper.

;
Func ShowStdOutErr($l_Handle, $ShowConsole = 1)
    Local $Line, $nbrChar1, $nbrChar2, $tot_out
    While 1
        Sleep(10)
        $nbrChar1 = StdoutRead($l_Handle, True)
        If $nbrChar1 Then
            $Line = StdoutRead($l_Handle)
            $tot_out &= $Line
            If $ShowConsole Then ConsoleWrite($Line)
        EndIf
        $nbrChar2 = StderrRead($l_Handle, True)
        If @error Then ExitLoop
        If $nbrChar2 Then
            $Line = StderrRead($l_Handle)
            If @error Then ExitLoop
            $tot_out &= $Line
            If $ShowConsole Then ConsoleWrite($Line)
        EndIf
    WEnd
    Return $tot_out
EndFunc;==>ShowStdOutErr

Jos

Thanks Jos I wasn't really expecting anything before your next official release. I very much appreciate it.

I'd forgotten about the recent changes to the Stdxxx IO functions as I don't use them very often.

The changes you have made seem to have fixed the problem. ConsoleWrites and error messages from Au3Check Obsfuscator etc. are now been written to the console correctly.


"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×