Gianni Posted March 22, 2013 Share Posted March 22, 2013 Good morning,I wrote a little script to "print" to the console some properties of the Internet Explorer displayed page (when not minimized).#Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Change2CUI=y #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include $ie_handle1 = winactivate("[CLASS:IEFrame]") ; get iexplore handle $oIE = _IEAttach($ie_handle1 ,"HWND" ) ; reference to $o_object ConsoleWrite("property" & chr(9) & "value" & @CRLF) ConsoleWrite("--------" & chr(9) & "-----" & @CRLF) ConsoleWrite( "locationname : " & chr(9) & _IEPropertyGet( $oIE, "locationname") & @crlf) ConsoleWrite( "locationurl : " & chr(9) & _IEPropertyGet( $oIE, "locationurl") & @crlf) ConsoleWrite( "offline : " & chr(9) & _IEPropertyGet( $oIE, "offline") & @crlf) ConsoleWrite( "readystate : " & chr(9) & _IEPropertyGet( $oIE, "readystate") & @crlf) ConsoleWrite( "referrer : " & chr(9) & _IEPropertyGet( $oIE, "referrer") & @crlf) ConsoleWrite( "theatermode : " & chr(9) & _IEPropertyGet( $oIE, "theatermode") & @crlf) ConsoleWrite( "title (doc) : " & chr(9) & _IEPropertyGet( $oIE, "title") & @crlf)I compiled the script and it works as well.But if i open a command prompt on my client and from there I try run the compiled scripton a remote machine with the following psexec statement:psexec.exe \\remoteclient -u dom\username -p password -i -w "c:\temp" "C:\temp\info_on_browser.exe"the output of the compiled script executed on the remote client is not returned back to the calling clientif i run the compiled script directly on the remote client from the keyboard in a dos prompt, it is executed correctly and the result is printedplease, does someone had the same problem with compiled script and found the solution?thanks a lot Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt.... Link to comment Share on other sites More sharing options...
BrewManNH Posted March 22, 2013 Share Posted March 22, 2013 You could send the output to a file that is written on the computer it's being run from. There's no command line parameter for PSExec to pipe the output of the program being run back to the calling computer. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
Gianni Posted March 22, 2013 Author Share Posted March 22, 2013 thanks BrewManNH for the reply....but psexec sends back the output if you do not use the -i parameter....I am playing with some tests to understand how psexec works:for example with the following psexec command:psexec.exe \\remoteclient -u dom\username -p password -w "c:\temp" IPCONFIGi get the output of the remote ipconfig on the local computerinstead with the following psexec statement:psexec.exe \\remoteclient -u dom\username -p password -i -w "c:\temp" IPCONFIG(-i parameter added) the output is not displayed on the local computerunfortunately with my compiled script i must use the -i parameter otherwise it hangs on the remote client because it must interact with the desktop and in turn with internet explorer.I would like to have the output of the script without the need of using a temporary filesuggestions are welcome thanksbye Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt.... 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