如何使用ASP.NET添加/更新环境变量 [英] How to add/update environment variable using ASP.NET

查看:57
本文介绍了如何使用ASP.NET添加/更新环境变量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我需要创建一个asp.net页面,它可以在客户机上添加/更新环境变量。我知道它可以通过vb脚本完成,但事实是从IE11开始,微软不会支持浏览器中的vb脚本。还有什么其他选择?



我尝试过:



使用vb脚本创建代码并且它可以工作但是微软或crome不支持vb脚本。

Hi,
I need to create an asp.net page which can add/update environment variable on client machine. I know that it can be done by vb script but the fact is from IE11 onwards Microsoft is not going to support vb script in browser. What are the other options?

What I have tried:

Created code with vb script and it works but vb script will not be supported by Microsoft or crome.

推荐答案

你不能。

这需要直接访问机器,并假设客户端正在运行Windows。

这些都不适用于服务器上运行的VB代码。

安全性单独不允许您的服务器代码修改客户端操作系统参数(有效的环境变量)
You can't.
That would require direct access to the machine, and an assumption that the client is running Windows.
Neither of these are available to your VB code running on the server.
Security alone will not allow your server code to modify client operation system parameters (which the environment variables effectively are)


这篇关于如何使用ASP.NET添加/更新环境变量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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