多个用户登录表单以启动应用程序 [英] Multiple users login form for starting application

查看:67
本文介绍了多个用户登录表单以启动应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好
我需要为多个用户创建登录表单以在应用程序上登录的示例.我正在使用Visual Studio 2010(C#语言)工作,数据源是accdb 2007数据库.
我想在启动应用程序时打开一个用户名/密码窗口,并且在登录时希望有一个输入数据的表单,我希望在该表单中以该用户的身份显示该用户.任何例子都会有很大帮助
谢谢

Hello
I need example for creating login form for multiple users to logon on application. I am working in visual studio 2010,C# language, and datasource is accdb 2007 database.
I want when starting application a username/password window to open up, and when logged on I have a form for input data where I want this user to be presented as logged on. any example would be great help
thanks

推荐答案

我写了一个有关您想要的东西的提示/技巧:

C#Apps中的多个后续主"表单 [ ^ ]
I wrote a tip/trick about something like what you want:

Multiple Subsequent "Main" Forms in C# Apps[^]


如果我有您的确切要求,请执行以下操作...

在成功登录用户后创建一个会话,并且当您希望该用户出现在该页面上时,请检查页面加载"中的Session变量是否不为null表示用户已登录,否则不登录.使用该会话变量的值.
If I got your exact requirement then do the Following...

Create a Session on Successfully Login of a User and when you want that user should be present for that page, check on Page Load if the Session variable is not null means user is logged in, otherwise not. Use that session variable''s value.


这篇关于多个用户登录表单以启动应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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