[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 593
  • Last Modified:

Alert User to change password.

Hi,

I am using SQL2005 n .Net 3.5

I have a field in my table as Updatedate which contain last update date of the password.

Now I want to force user to change his password after 60 days.Before this,I want to remind him for the password change from 54th day.

6 days left.
55th day 5 days left
..........
.........
60 th day.0 days left and now you have to change the password.

How to do this?
0
rajputamitd
Asked:
rajputamitd
  • 2
1 Solution
 
tigin44Commented:
create a stored procedure to control the password expiration and prepare your massages. In your application do always call this procedure while user login in as the first job. And take the required steps that neede to do...
0
 
rajputamitdAuthor Commented:
Can you guide me or show an example how to write such store procedure.
 
Thank u.
0
 
havj123Commented:
Either try this in code behind.
Just take the date value from updatedate field. Take days from the Date. Subtract it from Current date.

Then check it the number of days is greater than 53.
if(dt >53)
{
     int days = 60 - dt;
     label1.text = days + "days left";
}
0
 
rajputamitdAuthor Commented:
Thanks 4 ur reply.I'll try it later n let you know.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now