Verify which parsed timestamp folder is closer to the current timestamp
Hi,
I have "n" number of timestamps in a folder like :-
2010_08_04_15_14_57 (yyyy_dd_mm_h_mm_ss)
2010_08_04_15_15_57
2010_08_04_15_16_57
From these folders I need to pickup the latest(recent) timestamp folder, here it is 2010_08_04_15_16_57. For this to happen I need to check if any of these timestamp folders is close to the current timestamp, so that i can make sure that particular folder is the recently created one? How to find that whether the timestamp folder is close to the current Timestamp, because Calendar & Date classes have the before() & after(), but there is no API to find which of these timstamp folders are close to the Current timestamp? Please shed some light into this.
Thanks in advance.
AnanthJava wrote:
Hi,
I have "n" number of timestamps in a folder like :-
2010_08_04_15_14_57 (yyyy_dd_mm_h_mm_ss)
2010_08_04_15_15_57
2010_08_04_15_16_57
From these folders I need to pickup the latest(recent) timestamp folder, here it is 2010_08_04_15_16_57. For this to happen I need to check if any of these timestamp folders is close to the current timestamp, so that i can make sure that particular folder is the recently created one? How to find that whether the timestamp folder is close to the current Timestamp, because Calendar & Date classes have the before() & after(), but there is no API to find which of these timstamp folders are close to the Current timestamp? Please shed some light into this.
Thanks in advance.If there are no other type of files or folders in the the folder containing these time stamp folders then you can use File.listFiles() and use Arrays.sort() on them to give the most recent time stamp folder in the last element. If there are other types of folder and files, then it would be necessary to implement FileFilter and use File.listFiles(FileFilter). The advantage is you have a File reference to the time stamp folder you presumably ultimately need.
Edited by: pete_d on Aug 4, 2010 9:41 AM
how strange. I was replying when it got moved.
Similar Messages
-
The selected folder does not contain the current site's homepage
dreamweaver displays the following message when editting some
sites:
"WARNING: The selected folder does not contain the current
site's homepage. The site map cannot be built."
Then my remote info is cleared!
I know I'm obviously not doing something, but there is no
need to clear my remote info!!
edit: I've selected my home page, but this still doesn't
explain why Dreamweaver feels the need to erase my remote
info!!!> Then my remote info is cleared!
Huh?
This only means that you have not told DW which page is your
home page.
Find it in the local file list, and use the right-click
context menu to so
designate the file.
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com
- Template Triage!
http://www.projectseven.com/go
- DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs,
Tutorials & Resources
http://www.macromedia.com/support/search/
- Macromedia (MM) Technotes
==================
"ogre11" <[email protected]> wrote in
message
news:f2293h$7lg$[email protected]..
> dreamweaver displays the following message when editting
some sites:
>
> "WARNING: The selected folder does not contain the
current site's
> homepage.
> The site map cannot be built."
>
> Then my remote info is cleared!
>
> I know I'm obviously not doing something, but there is
no need to clear my
> remote info!!
> -
Close to the "current time indicator" there's a lighter gray section. What is it for?
Close to the "current time indicator" there's a lighter gray section. What is it for?
This is the correct answer.
1. Re: What mean Light GRAY COLOR near CTI?
Todd_Kopriva
That is answered in After Effects Help:
After Effects Help | Assorted animation tools -
If I am on a website and open a few different pages, and then decide to go back to an earlier page, or close that particular page, I get a message that says you are about to close 3 tabs or 4 tabs etc. If I only want to close the "current tab" I am on, I was able to do that with Internet Explorer. Is there any way this can be done on Firefox?
For more help, see the '''[[Tabbed browsing]]''' page.
-
Which of these cables is better for the current Macbooks?
I have a 2008 Macbook, with the mini displayport that can't output audio. I decided to rectify this by buying this cable, which combines video from mini displayport and audio from USB into an HDMI cable:
http://www.kanexlive.com/products/iAdapt20.html
now, I might be getting one of the new Macbook Pros that will be coming out in the next month or so, or one of the current models if the new ones take too long. so i'm wondering if I should replace the cable I have with one of these:
http://www.kanexlive.com/products/mdphdmi10ft.html
or
http://www.kanexlive.com/products/iAdaptV2.html
should I go ahead and get the upgrade? I figure it would be an improvement since those give better quality audio. I'm also wondering how my current cable would perform when plugged into a MDP that send audio on its own. could that cause a problem, since I would be out putting audio through 2 ports into the same cable? also, I wonder if the newer cables might have any problems due to getting power from the MDP instead of USB, I don't know whether that makes a difference or not.It doesn't matter which one you get since the Atom CPU has a 667MHz FSB.
If you install 800MHz RAM, it will simply run at 667MHz. -
MS's Intellimouse has five "buttons" including the scroll wheel. I set left and right buttons to L-click & R-click (seems normal). I set left side button to Back and right side button to Close.
In FF3, Close closes the current tab and Ctrl-W closes the window. In FF4, this is reversed -- Close closes the window and all its tabs and Ctrl-W closes the current tab -- not my preferred behavior.
The behavior switch in FF4 may or may not have been a function of what somebody had for breakfast. It is was, then I'd like it switched back. If there was an important reason for the switch, I'd like to know.
Until FF4 reverts to FF3 behavior, I'm probably stuck in FF3.
In anyhow, thanks -- John Linford, Fort WorthHarley, thank you so much. I'll reload FF4 and re-set the settings.
John -
When I hit the home key Firefox takes me back to my homepage (AOL) but also opens up a new Mozilla Firefox Start Page tab. I end up with a whole bunch of unwanted tabs.
== This happened ==
Every time Firefox opened
== alwaysHello Ginna.
Please check the following:
Click on '''Tools> Options'''.
Then click on '''General'''.
Now, it should say: '''http://aol.com/''' (or similar), but please check if it has anything after that. For example, if there is a '''|''' after it, that tells FF to open up 2 pages when you hit the home button: AOL and the other page, which in this case is a blank page.
If you see a '''|''' in there, go ahead and adjust it or remove it, if you'd like. If not, please report back here and let me know! -
At times I am on and off the net a lot and quickly. I will close out the current version. Then find I have to re-connect. When I try to activate firefox again I get this message that I have to close the previous version or re-start my machine. Can I stop this from happening? It is annoying and frustrating. Any suggestions would be appreciated.
See "closing Firefox" in
* http://dmcritchie.mvps.org/firefox/firefox-problems.htm#close_firefox -
Create a folder or file with the DATE as name?
I am finalizing a backup routine that involves a couple of Time Machine backups, a couple of Clones (backs up once a week or once a month) and a couple of "manual" backups that I store off-site.
Right now I have a txt file that I keep in my Home Folder with a underscore so that it shows up at the top of my Home Folder where I manually change the date so I can check that I have a current backup and/or I can know how current the backup is ("_20111126.txt" for today). Right now, between the Time Machine, the Clones and the "regular" backups I am not sure how to do this really easy in any other way.
Today I realized that I would find it uber helpful to have a file that did this in an automated manner every day since I got into Time Machine to check this backup and the file is the same name for weeks at a time since I rarely change it.
Is there a way to do this in an automated manner or in a way that is as visually immediate as this method?
TIA for any help.hotwheels 22 wrote:
i just want to have a file or a folder that always has the current date in the name so that when i see it in my documents or desktop on the backup i know that the backup ran successfully. does this make sense?
Not to me. What if the renaming script works, but the backup fails? What if the backup works, but the renaming script fails?
You should use a proper backup application. Such an application should keep a log and should provide proper notification of the results of the backup
are you saying that there is some method to do this with software called "Chron" or with iCal?
I'm saying that, if you want to run a script daily or on some specified date, the way to do it is with cron (without the h, sorry for the typo) or iCal.
In fact, Apple says that one should use launchd instead of cron, but cron is still supported. Cron jobs are set with crontab, and there are plenty of examples and instructions on how to use it, as well as some GUIs for it.
As to iCal, it's simply a matter of choosing to Run Script as an alarm for an event. (It's in the iCal help.)
Here
<http://superuser.com/questions/126907/how-can-i-get-a-script-to-run-every-day-on -mac-os-x>
you'll find a succinct discussion of cron, launchd, and iCal, and links to more info on accomplishing this task. -
Somebody help me, how can i consert Date to Timestamp. i want to parse
the Timestamp. but the parse method only return Date.
Please help.
best regards
NauWhen formatting Dates in java I've usually used the java.text.SimpleDateFormat class which gives a lot of flexiblitity in choosing your format. You may want to refer to the java.util.Calendar object also. Note that Date formats are not synchronized.
Here's a simple program that prints the current time in two formats:
package example;
import java.util.Date;
import java.text.SimpleDateFormat;
* @author pete
* To change this generated comment edit the template variable "typecomment":
* Window>Preferences>Java>Templates.
* To enable and disable the creation of type comments go to
* Window>Preferences>Java>Code Generation.
public class WhosGotTheTime {
public static void main(String[] args) {
// initially display hour:minute:second AM/PM
SimpleDateFormat formatter =
new SimpleDateFormat("h:mm:ss a");
Date now = new Date();
System.out.println("At the tone, the time is "
+ formatter.format(now)
+ "\n...tone");
// modify to display hour:minute:second:millisecond
// AM/PM and General Time Zone
formatter.applyPattern("h:mm:ss.S a zzzz");
System.out.println("\nAt the tone, the time is "
+ formatter.format(now)
+ "\n...tone"); -
Network folder opens/closes/disappears/reappears on its own (really)!
I have an external drive hanging off my Airport Extreme and accessed wirelessly. I just created a new folder on the drive to save some files I want to share with another machine on my local network. I copied some files to it (which didn't appear in Finder, then did appear. Wierd I thought. Now I'm seeing the following behavior:
- Open the network drive in Finder; Folder is at root level.
- Every few seconds, the folder does the following;
1 Folder Name switches from all upper (the way I created it) to lower case
and back again.
2 Folder disappears and reappears.
- Goto 1
- In addition, if I open the Folder (either with the turny triangle or by double clicking), the folder will open, display the contained files list, and then close itself and repeating the behavior above. I've never seen anything like this before. This Folder is the first I created on the network volume since "upgrading" to SL. All my software, system and otherwise, is up-to-date.
I'm starting to wish I had followed my usual policy of not updating to a new version of anything until it had some shake-out time and a maintenance update.
Any ideas?
-ddsboth my mbp's ( clip ) within 24" of the AE.
That close? No walls, rabbit cages or steel plates, then I guess
Got to wonder if they are now stepping on each other somehow.
What channels/freqs. have you tried so far? Any bluetooth in operation with each other? Can you see any change if you take any cell phones out of range. Any new garage door openers or new neighbors?
I understand your apparent concern that this is totally new and unique to the 10.6.1 install somehow breaking an apparently stable configuration - just be sure to check the basics as you go, and try to only make one change at a time. Don't let your suspicions blind you to any suspects, etc. Troubleshooting modern electronics can be a real time waster, I know -
Hi,
When trying to initiate hyper-v replication from the main server i'm getting this error in the event logs.
Hyper-V failed to enable replication for virtual machine 'RECADemo': A required certificate is not within its validity period when verifying against the current system clock or the timestamp in the signed file. (0x800B0101). (Virtual Machine ID 561591B6-567C-...)--I'm using certificate based auth and cert is installed/recognized on both machines.Please help.Thanks,Jaffer
JafHi,
This error occurs because the Microsoft Certificate Trust List Publisher certificate expired. A copy of the CTL with an expired signing certificate exists in the CryptnetUrlCache
folder. Please try to renew the Trust List Publisher certificate.
The related KB:
Event ID 4107 or Event ID 11 is logged in the Application log in Windows and in Windows Server
http://support.microsoft.com/kb/2328240
How to Renew the Site Server Signing Certificate (Microsoft Certificate Services)
http://blogs.technet.com/b/configmgrteam/archive/2009/02/11/how-to-renew-the-site-server-signing-certificate-microsoft-certificate-services.aspx
Manage Trusted Publishers
http://technet.microsoft.com/en-us/library/cc733026.aspx
Hope this helps.
We
are trying to better understand customer views on social support experience, so your participation in this
interview project would be greatly appreciated if you have time.
Thanks for helping make community forums a great place. -
How can i open the directory/folder and read all the files inside it in order and then close it? any example would be nice.
thanksIn the File I/O>>Advanced File Functions Palette is a function named "List directory". This function will give you two arrays. One contains the names of all subdirectories the other the names of all files. If you want to sort them by name use the array sort function. If you want to sort them by another attribute use the File/Directory Info function to get more data. Use a cluster which contains the attribut to sort and the original index of the name. Then sort this array.
Waldemar
Waldemar
Using 7.1.1, 8.5.1, 8.6.1, 2009 on XP and RT
Don't forget to give Kudos to good answers and/or questions -
How to find out which user create folder
how to find out which user create folder in shared drive?
Hello,
you have to enable Auditing in on the DCs OU and also on the top folder level where this should be monitored.
http://technet.microsoft.com/en-us/library/cc784387(v=ws.10).aspx
http://support.microsoft.com/kb/310399
Best regards
Meinolf Weber
MVP, MCP, MCTS
Microsoft MVP - Directory Services
My Blog: http://msmvps.com/blogs/mweber/
Disclaimer: This posting is provided AS IS with no warranties or guarantees and confers no rights. -
I have redeemed my iTunes giftcard (which was accepted without verification; it only needed my password)
However when I tried to make a purchase, I am required to verify my identity, and thus I cannot use the giftcard which I HAVE REDEEMED. Is there any way I can un-redeem it? I am currently trying to enter all of the possibilities for my questions, and my iPad is new, so the serial number is not registered with my account. According to support, no purchases have been made in my account, so I can't verify my identity through credit card. Please help!~You need to ask Apple to reset your security questions. To do this, click here and pick a method; if that page doesn't list one for your country or you're unable to call, fill out and submit this form.
If you just want to have the card un-redeemed, use the form.
(123638)
Maybe you are looking for
-
Please, help with AS2 / CS3
In this zip file, I replaced the images, with blank photos, with the image titles, to make it easier to see the problem. (download files) http://www.pbsjbuzz.tv/site_flash/site_flash.zip (view online) http://www.pbsjbuzz.tv/site_flash Thank you ! Hel
-
HP LaserJet 1320 requires user intervention to print after Leopard
Ever since upgrading to Leopard, almost every single time I send a print job to my HP LaserJet 1320 (over the network, it actually connected to a PowerMac G5 in my office), it triggers an error warning (orange flashing light) on the printer. Pressing
-
Copying old iTunes library onto a new hard drive: special question:
How do i do this when the music in my old iTunes library was not all in the itunes media folder (some was in downloads, shared folder, etc). Should I put these folders in the places where they were on my old hard drive (for example the "shared" folde
-
please help!
-
I have about 10 VPN clients connecting to a Cisco ASA 5510. I am getting calls that sometimes people are getting 413 errors here and there. When they out it username and password, the dialog box pops up again and then they get a error 413 cannot auth