Click here to Skip to main content
15,898,987 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Hi,
I'm using visual studio 2005 and I created one website for my company. I created Employee Login form. When Employee Logs in, his login time is automatically stored in database. How can I do that.
Please somebody help to do this.

[EDIT] - Tried to make language simple. Please check is this what you meant to ask ?
Posted
Updated 17-Aug-12 2:37am
v2
Comments
bhagirathimfs 17-Aug-12 8:22am    
Please briefly explain the question?
You have developed a login Form and want to connect to database????
OR
You are already made connection with database and want to store the time of login???
[no name] 17-Aug-12 9:15am    
This makes no sense. You told us what you have already done and then ask how to do that? What have you done? What errors are you getting? Where is the code that demonstrates any kind of a problem?

1 solution

You can use DateTime.Now to get the current local datetime. You'd have to ask the user for their time zone to know the time where they are. Then stuff it in the DB.
 
Share this answer
 

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