以Windows形式切换用户

编程入门 行业动态 更新时间:2024-10-07 08:24:58
本文介绍了以Windows形式切换用户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

大家好! 我创建了一个应用程序,该应用程序的安全模块是当用户位于域中时可以使用该应用程序 如果用户不在域中 他可以切换用户 我如何在不关闭应用程序的情况下以编程方式切换用户

hi to all! i create an application whose security module is when the user is in domain can use the application if the user is not in domain he can switch user how can i switch user programitacially without closing the application

推荐答案

在您知道凭据的情况下尝试模拟新用户,否则从对话框中请求凭据然后模拟 看看此使用C#的Windows模拟 [ ^ ] Try to impersonate the new user in case you know the credentials , else ask for the credentials from a dialog then impersonate Take a look at this Windows Impersonation using C#[^]

你好kami124. 问题尚不清楚.您想更改应用程序用户还是Windows用户? hello kami124. The question is not clear. You want to change the users of your Application Or windows users??

尽管以上两个都是很好的答案. 此处是一个支持该功能的应用程序 登录,切换用户和注销只需尝试一下. 希望对您有帮助 Though above both is good answer. here is one application which supports the functionality Login, Switchuser and Logoff just try it. Hop it will help you

更多推荐

以Windows形式切换用户

本文发布于:2023-07-22 14:56:43,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1188581.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:形式   用户   Windows

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!