Bacilic Posted April 26, 2015 Share Posted April 26, 2015 (edited) The company we have 30 computers running windows 8.1 and three lines ADSL, what I want is to change on occasion the ADSL line. After many hours searching on autoitscript.com/forum and on Google, I came to the solution of PsExec.exe together with netsh. Eventually the command that I use and it works is as follows:$sParameter = "netsh interface ip set address ethernet static 192.168.1.250 255.255.255.0 192.168.1.3" $sComputerName = "PCE04 " Run("C:\PSTools\PsExec.exe \\" & $sCompureName &$sParameter)The problem is that I want to see the gate (= ADSL line) before the change.Other so many hours searching to arrive at a method to store ipconfig in a txt file.While locally works fine, when I want to run the ipconfig for the client does not work!If you do the command PsExec.exe \\[ComputerName] ipconfig > C:\Pcip.ini copying the command prompt of windows 8.1 works perfectly, just to embed in autoit not create the file.$sComputerName = "PCE04 " $res = RunWait(@ComSpec & "PsExec.exe \\" & $sComputerName & "ipconfig > C:\PcIP.ini", "", @SW_HIDE) If $res = 0 Then $Output = FileRead("C:\PcIP.ini") MsgBox(0, "CMD Output", $Output) EndIfQuestions:Is there any other way to get a variable with a gateway of client?Is there a way to export the data to PsExec.exe \\ ComputerName ipconfig in a txt file to copy from there the gate?I hope to help. Edited April 26, 2015 by Bacilic Link to comment Share on other sites More sharing options...
zalomalo Posted April 26, 2015 Share Posted April 26, 2015 I had the same issue, in same envoirment after migrating from XP to win8.1, was easy in XP. I must go eat now bot could help you with my solution, when came back....the way is powershell.... My english shucks, i know it. Link to comment Share on other sites More sharing options...
Bacilic Posted April 28, 2015 Author Share Posted April 28, 2015 Finally I found a solutionis to enable the Remote Registry service of windows 8 at client (Launch services.msc, and then the Remote Registry).After with a RegRead () can read information that you want, remotely.Tried and RegWrite () but while changing the values in the registry does not correctly update the network adapter. I think this is an issue of windows 8 and requires an in-depth investigation. 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