开发者

Windows system login credentials

开发者 https://www.devze.com 2023-04-06 21:40 出处:网络
i am developing a scheduler in which i want to match the username and password entered by the user 开发者_Python百科with the system\'s login credentials in c#.Is there any way to do this.Why don\'t yo

i am developing a scheduler in which i want to match the username and password entered by the user 开发者_Python百科with the system's login credentials in c#.Is there any way to do this.


Why don't you use the Windows Task Scheduler?

Just look http://www.codeproject.com/KB/cs/tsnewlib.aspx

BTW you can gather the currently logged on user by using System.Environment or from the current Thread.


 WindowsIdentity.GetCurrent().Name;


Getting the default credentials for the current user:

CredentialCache.DefaultCredentials;
0

精彩评论

暂无评论...
验证码 换一张
取 消