如何在C#的Admin命令提示符下运行命令? [英] How to run commands in a Admin Command Prompt in C#?

查看:124
本文介绍了如何在C#的Admin命令提示符下运行命令?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我找不到一个好的解决方案,我需要执行CMD命令,但它必须在管理员CMD中。我在网上找不到任何好的答案:(



我喜欢进行注册编辑但出于安全原因它被阻止(它需要在admin)

I can''t find a good solution for this, I need to execute CMD Commands but it must be in the administrator CMD. I can''t find any good answers in the net :(

I like to make a register edit but it is Blocked for security reasons (It needs to be in admin)

推荐答案

http://blog.bartwolff.com/post/2012/06/19/Running-with-elevated-privileges-from-C.aspx [ ^ ]

http://jpassing.com/2007 / 12/08 / launch-processes-processes-from-the-line-line / [ ^ ]


这篇关于如何在C#的Admin命令提示符下运行命令?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆