c# - Write Date of last password change -
i in process of making asp.net c# website , need output last time user has changed password label.
do need create seperate tabel in database this? or there function can call somewhere?
i did research , believe have use:
public virtual datetime lastpasswordchangeddate { get; }
but cannot find out how implement website examples find use create system force users change password after set amount of time , not write current value string.
any appreciated.
problem solved,
membershipuser u = membership.getuser(); pwchangedatelabel.text = u.lastpasswordchangeddate.tostring("d/m/yyyy");
i'm guessing using sqlmembershipprovider membership provider?
you should able use this:
membershipuser u = membership.getuser("example@example.net"); txtpasswordchanged.text = u.lastpasswordchangeddate.tostring("m/d/yyyy");
Comments
Post a Comment