如何创建角色将在数据库中?将在、数据库中、角色

2023-09-04 23:25:43 作者:三千繁華 虛夢壹場

我希望在此之后,用户身份验证(登录)来访问应用程序,我将给予一定的作用,并保存在数据库中的作用为每个用户创建一个角色。 我将与数据库aspnet.mdf的例子和LINQ toSql来存储数据,但之前我需要知道如何在C#中(WPF)的作用,创造了后,我希望在数据库中添加角色这样我可以分配为每个用户我希望合适的角色。 你有一些想法是怎么做的吗??? 我将使用数据库aspnet.mdf作为例子,因为我认为这很好只是为了测试我的应用程序(我需要这个功能来开发一个项目)。

i wish create a role for each user after that the user authenticate(login) to access to the application i will give some role to and save the role on the database. I will make an example with the database "aspnet.mdf" and Linq toSql to store data but before i need know how create role in c#(WPF) and after created i wish add roles on the database so doing i can assign for each user the right role that i wish . DO you have some idea how do it right??? I will use the database "aspnet.mdf" as example because i see it good just to test my application (i need this feature to develop a project).

多谢了。

尼斯的问候,

再见

推荐答案

您不知道。

如果您使用的是ASP.NET的成员资格框架,你没有使用LinqToSql去碰它。您可以使用ASP.NET的会员框架。

If you're using ASP.NET's membership framework, you don't touch it using LinqToSql. You use ASP.NET's membership framework.