As the title hopefully made clear...I want to restrict the access of a user data control so anonymous users (ones who havent registered with my site) can't access its contents.
I read about restricting access to specific roles and I understand how it works for specific pages (forms) but I was unable to find anything about denying access to a specific control on a page.
Here's the scenario...on my Default.aspx page I have a linkbutton that once clicked will make a table in a placeholder visible. Inside this table are 2 text boxes and a button that I only want accessible to users who have registered. Everything else on the site I want accessible to anonymous as well as registered users.
This is just coming off the top of my head and I don't even know if this is remotely close to correct but since you can use the Context.Identity.User.Name (I think that's correct) to show the name of the specific user...is there something like Context.Identity.User.Role = "Anonymous" where I could throw in a loop to restrict access?
Anything you guys can provide is greatly appreciated! Thanks!