WPF 桌面中的简单用户会话示例

发布于 2024-11-07 13:33:32 字数 390 浏览 3 评论 0原文

WPF 桌面应用程序中是否有任何不错的简单用户会话示例(或教程)?

我的应用程序包含一个实体框架库、几个内部类库和一个 WPF 项目的表示层。我们目前没有连接任何 Web 服务或构建 WCF 层。

尽管如此,人们仍会使用 Citrix 帐户登录应用程序 - 许多人可能使用相同的帐户(那里是客户端的设计),因此我想为每次登录创建一个用户会话。这在桌面上有多容易处理?我在 codeproject 上找到了 WPF 桌面自动注销示例 ,但没有登录/会话的基本实现。到目前为止,我发现的所有 WPF 会话信息都是基于浏览器的,主要涉及 WCF 服务。

Are there any decent examples of (or tutorials on) simple user sessions in a WPF desktop app?

My app contains an Entity Framework library, a couple in-house class libraries, and a presentation layer that's a WPF project. We're not presently hooking into any webservices or building a WCF layer.

Still, people will log into the app using a Citrix account- with many people possibly using the same account (client's design there), so I'd like to create a user session for each login. How tractable is this on the desktop? I've found an Auto logoff example for WPF Desktop on codeproject, but no basic implementations of the logon/session. All the WPF session info I've found so far has been browser based, mostly hitting WCF services.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

看轻我的陪伴 2024-11-14 13:33:32

用户会话是什么意思?根据您的描述,我假设您希望用户登录您的应用程序(与 Windows 登录分开)。如果这就是您的意思,那么您基本上将使用数据库来滚动您自己的用户和会话管理系统。我会根据其他人已经做过的事情进行建模,但您可以简化它以满足您的确切需求。下面是 ASP.NET 会员系统的 WPF 接口示例。您可能想要创建类似的东西(尽管如果您不需要角色等,它会让事情变得更简单)。

http://wpfmembershipadmin.codeplex.com/

What do you mean by user session? I would assume by what you are describing that you want your users to log in to your app (separately from their Windows login). If this is what you mean than you will basically be rolling your own user and session management system using your database. I would model it off of what others have already done but you could simplify it to meet your exact needs. Here is an example of a WPF interface into the ASP.NET membership system. You would probably want to create something similar (although if you don't need roles and such it will make it much simpler).

http://wpfmembershipadmin.codeplex.com/

一场春暖 2024-11-14 13:33:32

根据 @Matt_West 的回复进行的搜索,我被引导到这样一个事实:我不应该在 WPF 中搜索“用户会话管理”,而应该搜索“会员服务”。一旦我这样做了,我发现了 WPF 中的会员服务 SO 主题

Based on searching due to @Matt_West's response, I was guided to the fact that I shouldn't be searching for "user session management" in WPF, but for "Membership Services." Once I did that, I found a SO Thread on Membership Services in WPF

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文