w0uter Posted September 24, 2005 Posted September 24, 2005 for all the people that have trouble using STD Func _RunSTD($s_p, $s_wd = @WorkingDir, $s_f = @SW_HIDE) Local $s_r = '', $i_pid = Run($s_p, $s_wd, $s_f, 2) While Not @error $s_r &= StdoutRead($i_pid) WEnd Return $s_r EndFunc ConsoleWrite(StringReplace(_RunSTD(@ComSpec & ' /c ipconfig /all'), @CR, '') & @LF) My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll
erifash Posted September 24, 2005 Posted September 24, 2005 Nice work w0uter! This could be really helpful for the new people. My UDFs:_FilePrint() | _ProcessGetName() | _Degree() and _Radian()My Scripts:Drive Lock - Computer Lock Using a Flash DriveAU3Chat - Simple Multiuser TCP ChatroomStringChunk - Split a String Into Equal PartsAutoProxy - Custom Webserver
blitzkrg Posted October 3, 2005 Posted October 3, 2005 if i wanted to see the "output" of say a telnet session or ftp session could i use this? lets say i need to authenticate to a firewall via telnet so i write a script to run telnet and then enter my login and pw. if i wanted to watch this process but not interact, could it be done?
DaveF Posted October 4, 2005 Posted October 4, 2005 (edited) if i wanted to see the "output" of say a telnet session or ftp session could i use this?lets say i need to authenticate to a firewall via telnetso i write a script to run telnet and then enter my login and pw.if i wanted to watch this process but not interact, could it be done?Kind-of, yes. There are examples on this forum that do the latter part of what you describe, by AutoIt capturing the output of a console process and displaying it, in a GUI edit box for example, as in the example linked above.The problem with doing specifically what you've asked is that Windows telnet won't run if the standard input is redirected (or XP's won't at least) which prevents AutoIt from entering "interactive" commands on your behalf.I've used Console Telnet as a replacement for the Windows version, and I know that other forum users have used Plink because it will do both telnet and SSH.for all the people that have trouble using STDThanks for this UDF, @w0uter, and I should have said so before now.If you can come up with a UDF for _StdxxxReadLine I'd be interested to see how you'd make it work. Edited October 4, 2005 by DaveF Yes yes yes, there it was. Youth must go, ah yes. But youth is only being in a way like it might be an animal. No, it is not just being an animal so much as being like one of these malenky toys you viddy being sold in the streets, like little chellovecks made out of tin and with a spring inside and then a winding handle on the outside and you wind it up grrr grrr grrr and off it itties, like walking, O my brothers. But it itties in a straight line and bangs straight into things bang bang and it cannot help what it is doing. Being young is like being like one of these malenky machines.
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