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 9204381
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T23:41:58+00:00 2026-06-17T23:41:58+00:00

When the contents of the folders are modified, the system does not update the

  • 0

When the contents of the folders are modified, the system does not update the modified date of the folders. Is there a way to set folders as modified when their contents are modified?

I tried to rename the folder to something else and renamed it back, but this doesn’t change the date modified of the folder. When I do rename the folder however, it does update the date modified, but I don’t want to rename the folder just for this. . . Maybe set something to the folder that is not a big deal each time the content is changed? I just need the code to alter folder and update its date modified. The listener for the content change is not needed.

Thanks in advance for your answers.

p.s. This is problem for me because I am using folders for listView and listing them by the date modified. Clicking the folder opens the content of the folder in another activity.

  • 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-17T23:41:59+00:00Added an answer on June 17, 2026 at 11:41 pm

    Have you had a look at the Android reference?

    public boolean setLastModified (long time) should do what you are looking for.

    Using it is as simple as:

    fileOrFolder.setLastModified( yourDateInMilliseconds );
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How does Windows Explorer determine the Date Modified field for folders? [Aside: I know
I am trying to copy the contents of certain folders to another folder using
I'm looking for a straightforward way to watch the contents of a folder using
Is there an method to get the contents of a folder in a particular
I want to make a procedure that does one way syncrhonization of a folder
This requirement is very specific to read directory contents along with date modified for
I have modified some folder icons and I am including these folders in my
Is there a way to select only those files that have the Modified status?
i want to show the folder contents in my windows form from where user
If I enable directory browsing in IIS it displays folder contents to user. Is

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.