Click here to Skip to main content
15,879,474 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi

help me about login object oriented code
Posted
Comments
CPallini 2-Sep-10 3:39am    
Please stop posting fake answers. Modify instead the original request.

This is not a question, it's a show of ignorance. There's tons of books you can read, tons of websites you can read, and if this is the best you can do to form a question, then you need to learn a lot more about programming before you worry about writing code that involves security in any way.
 
Share this answer
 
Comments
CPallini 2-Sep-10 3:38am    
"it's a show of ignorance" - bit harsh but honest.
I've reviewed your other questions, you're obviously in the middle of some sort of course, although it's insane, based on the level of experience shown in your other questions, that your class would have you writing ASP.NET code at all, let alone worrying about login controls. The only other option I can think of is that you tried to work through a basic C# book because you'd accepted an ASP.NET job on a rentacoder site. If the former is true, you need to stop asking here, and instead talk to your teacher. This is a great site for programmers to get help, but you're not yet at a level of being able to understand the answers we can give, which means it can't really help you, yet.

If you're taking paid work when you know nothing about programming, then you are a fraud and you should stop it.
 
Share this answer
 
Comments
setareh51 2-Sep-10 3:31am    
Please speak sincerely
Christian Graus 2-Sep-10 3:37am    
I am very sincere. Your question sounded like you wanted to create real login code. You even tagged it ASP.NET. Now it's clear you're asking about your course, my advice is that you need to talk to your teacher, or you need to do a better job of asking questions. Your initial post here was useless. You need to post with code and a real explanation of where you need help.
i have :

members class that admin class and user class derive of the members class

how i know that when login performed that it is admin or user ?
public class members
{
private string email;
}

public class user:members
{
private string password;
}

public class admin:members
{
private string password;
}
 
Share this answer
 
Comments
Christian Graus 2-Sep-10 3:27am    
OK, so you're writing for your class, this is not code anyone is going to use ? your OO structure makes no sense, if both admin and members have a password, why is it not in the base class ? What are you trying to achieve exactly ? I really think that you need to talk to your teacher. You, after being told many times, can't even understand to not push answer when you're asking a question, nor have you been able to understand any of the help you've been given. I don't see why that's going to change any time soon, esp as your question is becoming more and more nonsensical. How is this class structure going to help you create login code ?
setareh51 2-Sep-10 3:39am    
if both admin and members have a password, why is it not in the base class ?
because password is special attribute for person that it is Secret
Christian Graus 2-Sep-10 3:41am    
But it's hidden by the class. How does it differ ? Where does your data come from ? You can't set it, based on this code.
setareh51 2-Sep-10 3:49am    
how i know that admin logined or user logined so not out from oop.
setareh51 2-Sep-10 3:52am    
how i know that admin logined or user logined so not out from oop.
I think that nobody don't understand object oriented programming very good that some of you like Christian Graus says that i don't know programming.
 
Share this answer
 
First of all learn 3-tier architecture then you can know how to write the code.
 
Share this answer
 
Comments
Christian Graus 2-Sep-10 3:02am    
Not entirely true. This person sounds like they need to start a lot further back than 3 tier, and you don't need 3 tier architecture to write login code.
demouser743 2-Sep-10 3:05am    
Christian what ever he need that could be written in different ways on by creating a 3-tier or adding class files to an app folder and using them by creating an objects
Christian Graus 2-Sep-10 3:06am    
Reason for my vote of 1
Yes, he COULD make it work by creating a 3 tier system, but if he understood the concept of a 3 tier system, it wouldn't mean that he knew how to write the code, or how to read documentation, or use a login control.
demouser743 2-Sep-10 3:08am    
Even by using login controls too he can not get the object oriented code right
setareh51 2-Sep-10 3:56am    
how i know that admin logined or user logined so not out from oop

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900