Jump to content

Pipe commands to compiled .exe


Recommended Posts

Is it possible to pipe a command to an AutoIT .exe

eg: dir /b | myautoitexe.exe

It works if i run myautoitexe.exe param param, but does not seem to accept piped params.

TIA

I'm not sure if that can be done - but here is a free bump.

Welcome to the forum.

[size="1"][font="Arial"].[u].[/u][/font][/size]

Link to comment
Share on other sites

  • 1 month later...

Oooh! Good question! I'd be interested to know if you can do something like:

dir | find ".txt" | MyAutoItScript.exe

:)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

piped commands write to the stdin of the proccess they are piping to. Somthing simple like-

$a=""
while 1
    $a=ConsoleRead(512)
    if $a<>"" then MsgBox(0,"Read",$a)
WEnd

Go to the command line and run:

DIR | FIND /I ".exe" | Test.exe

Sweet! :)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

  • 2 weeks later...

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...