Click here to Skip to main content
15,881,424 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

I want to execute a command say ipconfig in remote computer so could you please let me know whether we need to configure anything in remote computer .y

Also is it necessary for the remote computer to have powershell installed in it.
BillWoodruff 11-Dec-14 4:17am    
Have you thought about the security requirements for this ?
superselector 11-Dec-14 4:26am    
Yes the command will be executed with full admin privileges by windows Administrator.

1 solution

I'd start here to try and, first, define the issues you will need to address in executing a PowerShell script on a "remote" computer via C#:

CodeProject article: Enable Remote PowerShell Execution in C# Jun 3, 2014: [^] "... describes how to execute PowerShell scripts locally or remotely in C# code."

And, I suggest you also study these:

PowerShell module in C#, Part 1: The basics Mar 18, 2014: [^] "In this series we will cover the basics of building a Windows PowerShell binary module using C#."

CodeProject article: How to run PowerShell scripts from C#: Mar 31, 2007 [^] "An article on embedding and/or launching PowerShell scripts from a C# program."
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900