Dragged and dropped a login control onto a blank content page. Set up my web.config (i'll include the code for that at the end). It seems to want to use a sql database to store the info. I just want to use the web.config since it's just a single user and a simple site. I thought I could just drag and drop the login control to a page and that would be the end of it (besides setting up the web.config).
I have read the post at http://forums.asp.net/t/1403132.aspx regarding login control. Is there a place to store the User logged-in ID (info) for later checking and use? I don't need to use the session object. I don't need the page to expire. I don't need the user to use a page saved in the favoites.
I've been reading others questions regarding storing settings in the web.config. Most of you agree that's a good way to store settings.I just have another doubt about that.
In my app, I need to map some ID's in the web.config. For example: [Table = UserType] 1 - User /2 - Admin
Is it a good idea to store these settings in the web.config so I know what is the right ID in my application? Do you have a better solution?
I'm trying to find out how i store user names and passwords in the web.config file. I have tried looking for documentation on this but haven't found any so far.
I see in the class library it says that the Authenticate method of the FormsAuthentication class is for use in authenticating credentials against those stored in the config file, but i don't know how to store them there to begin with. I want to store two username:password pairs in the web.config file preferably encrypted.
one of these username:password pairs i want to be hard coded. The other i want to be able to be reset with a password reset form which I will code later. I guess there maybe a method for creating a sername:password entry in the web.config which could be used with my password reset form if such a method exists. But I need to know how to hand code the username:password entries into the web.config file to begin with and to beable to create the hard coded pair.
code I need to add to my web.config file i need to add and in what section?
also can you point me in the direction of a method used for creating username:password entries in web.config
I created a table(UserProfile) to store additional user info and create foreign key relationship btw UserId of UserProfile table & asp.net_Users table.
When i run the createuser page i have this error:
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_User_Profile_aspnet_Users1". "dbo.aspnet_Users", column 'UserId'. The statement has been terminated.
I register all my user controls in the web.config file. In one of the modules of my application, I need to load a control dynamically. Is it possible for me to read the section of the web.config file where I have my user control data so that I can get its path directly from web.config?
i want to create a arraylist which will able to store user info like (username,machineIP,port ) for each user in the list & retrive this data when needed . any one tell me how i can do it or any alternative way without database or xml file.
I am using the Login control on my login.aspx page to login to my /Members/Default.aspx page to display their current weight and their goal weight using the DetailsGrid. I have everything setup and I can log in and verify the user login name, but it only give one weight regardless of who logs in. Below is the SQL for the SQL Source on the DetailsGrid. I am new with this, Comparing the UserNames on aspnet_Users.UserName and memInfo.UserName should be able to extract that data, correct? Obviously I'm missing something. :)
SELECT memInfo.curWeight, memInfo.goalWeight FROM aspnet_Membership INNER JOIN aspnet_Users ON aspnet_Membership.UserId = aspnet_Users.UserId INNER JOIN memInfo ON aspnet_Membership.UserId = memInfo.UserId AND aspnet_Users.UserName = memInfo.UserName
Is there an easy way to select a specific user that is already logged in and bind all the users info to a detailsview for edit and saving back to the tables?The tabels were generated in AWAT of VS 2010
If I'm correct the membership functionality separates account and user (profile) data in two tables. Why not one table? What's the design priciple behind this?
Our application lets the administrator create new users. Since the administrator is logged in, I have set Logincreateduser = false so that the administrator is not logged out even after creating the new user.
The problem is :I need the userid of the newly created user to store additional details of the user in another database table. I see that i can get the username using Createuserwizard1.username; but how do I get the userID?
I have a custom membership user class and custom MembershipProvider working against database. Due to security reasons the user passwords are stored in the database as hashed values. So my procedure
public override bool ValidateUser(string username, string password) is { //select hashed password from db return (EncodePassword(password) == dbpassword) } [code]....
Ive been exploring the tabls in the membership database to see how they are structured. If i add a new user or update an existing one i see it in the user and membership tables. But i dont understand how to use or store roles. I use the ASP.NET CONFIGURATION toll in the WEBSITE menu to create roles and create access rules, but those roles dont show up in the Roles table in the db!
Yet the roles are stored cause they keep apearing in the ASP.NET CONFIGURATION. How weird is not that? Where is it stored and how can i access it? I need to programatically check if the user who is logged in is in a certain role.
I have spent hours on the forum trying to find this answer. I have a requirement on a project. There is an internal (intranet employees only) site which has much more control over the data etc. and i have an external site (to allow customers to enter usage data). I am using forms auth and hitting a common sql server 2008 db with the standard aspnet schema. I have an internal web server and an external web server both windows 2003. The problem that i am having is that if you are logged into the external site and then open a new ie window and enter into the internal site, even as a different user it logs you out of the external and vice versa. I don't have access to update the machine config.
I started out as a single app in the db but now have seperated into 2 apps and i am able to log in as an external admin and see only the external users and vice versa. Creating a seperate security only db for the external app is not an option because i have a I have the application name listed in the web.config for both internal and external which matches the app name in the aspnet_applications table.
I try to get the user profile settings with this code. But all items in it are empty, in the database they are not empty. So there is going something wrong. First of oll how can i add a provider to the ProfileCommon ? Maybe i'm there then... the usrInfo is filled well...
I have created an asp.net site with anonymous access turned off. Its for an internal (intranet) system which uses User.Identity.Name.ToString() to get the users login windows ID and then displays some records from a datagrid depending on their login ID. Is this secure? Also i am struggling to workout how best to store the result of User.Identity.Name.ToString() as I am not keen on storing it in a hidden text field and would rather not call it all the time unless this is the best way?
I like to create a new user webform. I like to have multiple textbox fields for the new user to enter and would like to use the inbuilt ASP SQl express to administer. I read somewhere to use Membership.CreateUser API but not sure what that is?
Is it as simple as dropping textbox in a webform and in webconfig options place a line of code?
So I want to store customer information based on radiobuttonlist selections. The radiobuttonlist items are pulled from a database. When the customer makes a selection I want that selection to be stored in a database to record their order. There are 7 radiobuttonlists. So when they make a selection on one item, they are moved along to the next item. I want this to continue through all 7, store the information in a database and then produce a order summary at the end.
I am evaluating ASP.NET Membership for an intranet Silverlight app. I want users to be automatically authenticated for my application with their windows logon. Thus I configured Windows Authentication. I would like to store user settings like email-address in using the SqlMembershipProvider and not AD. It seems that storing user settings using the SqlMembershipProvider is not supported with Windows Authentication. Is this really so (using .NET 4)?
If so: What is the rationale behind this? IMHO authentication, user settings and authorization are distinct aspects. User settings could easily be stored (identified by user name) using the SqlMembershipProvider with authentication and password management being supplied by Windows. What is the recommended solution for my scenario?