Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7986255
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T11:48:18+00:00 2026-06-04T11:48:18+00:00

I am using directory services to get the last date the user changed his

  • 0

I am using directory services to get the last date the user changed his password. If this date was within 5 minutes I want to show a particular webpage when the user logs in. So for example a user gets prompted to change password. Rigth after changing windows password they login, because the change was within the 5 minute time frame the user will be presented with say google.com. If the user logs off and logs back in tomorrow nothing would happen. Here are some ideas I had but don’t work.

if(datepasswordchanged < datepasswordchanged.AddMinutes(5))

However this would happen everytime.

I also had

if(DateTime.Now.AddMinutes(-5) == datepasswordchanged)

however this would only happen if it was exactly 5 minutes ago. How could I specify a range?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T11:48:20+00:00Added an answer on June 4, 2026 at 11:48 am
    if(DateTime.Now < datepasswordchanged.AddMinutes(5))
    

    will be “If current time is less than five minutes after time in variable.”

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm currently trying to authenticate via Active Directory Services using the PrincipalContext class. I
How to get the file names inside a directory using PHP? I couldn't find
I'm trying to run a simple LDAP query using directory services in .Net. DirectoryEntry
How can i get the IADs interface of an Active Directory user - by
When running my SSIS using LDAP, I get this error on my ADO Datasource:
I'm going to get data with Restlet of this official OData page: http://services.odata.org/OData/OData.svc/ I've
I am using a WCF service to expose certain Active Directory management functions to
We are experiencing a performance problem when communicating with the active directory using System.DirectoryServices.
I chrooted directory using following commands: os.chroot(/mydir) How to return to directory to previous
I am working with Active Directory using C#. Instantiating the PrincipalContext object seems to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.