This project is read-only.

what is the correct DateTime format for AddSelectedFiles?

Feb 24, 2012 at 4:21 PM

I am trying to pass DateTime criteria to the AddSelectedFiles function. However, I keep getting errors regarding the format of the information I am passing. I know that a date format of "yyyy-mm-dd" will work but, I need to pass in the time as well. 

I haven't been able to find an example of the time format in any of the documentation or the examples I have seen.

Can someone point me to the correct format?


Thanks very much.

Feb 24, 2012 at 5:04 PM

After about an hour of searching the web, I found the answer at:

Here is the sentence I wanted:

"To specify a time, use YYYY-MM-DD-HH:mm:ss or YYYY/MM/DD-HH:mm:ss as the format. If you omit the HH:mm:ss portion, it is assumed to be 00:00:00 (midnight)."

The second format given (YYYY/MM/DD-HH:mm:ss) does not seem to work...I still got the incorrect format error but, using the first format provided (YYYY-MM-DD-HH:mm:ss), except with all lower case letters (yyyy-mm-dd-hh:mm:ss) seems to work. At least, its not throwing an error.

So...moving onward...

Feb 26, 2012 at 10:47 AM

Surely using all lower case letters will result in the month number (MM) being replaced with the number of minutes?? This doesnt seem like .NET wold format the date correctly using all lower case

Are you sure this works correctly?

Mar 21, 2012 at 2:17 PM

You're right. Here is the format I am using: yyyy-MM-dd-HH:mm:ss