The system cannot find the file specified

Started by justanoob23, August 24, 2023, 05:25:49 PM

Previous topic - Next topic

justanoob23

I've used exiftool a very small amount a few years back on MacOS. Now I am using Windows 10, and running into the subject error. The file certainly exists. My commands are below if someone could see if I'm doing something wrong? I have tried with and without quotes, shouldn't make a difference for file path without spaces though. Tried doing an entire directory recursively and also a specific file. I get the same error.

exiftool '-filename<CreateDate' -d %Y%m%d_%H%M%S%%-c.%%le -r "C:\Temp\Pictures\"
exiftool '-filename<CreateDate' -d %Y%m%d_%H%M%S%%-c.%%le "C:\Temp\Pictures\1.jpg"

ArchZu

#1
It's only %%e, not %%le for original file extension.
See: Common Date Format Codes

exiftool '-filename<CreateDate' -d %Y%m%d_%H%M%S%%-c.%%e "C:\Temp\Pictures\1.jpg"

From what I've seen, you need to have CreateDate defined to be able to use it.
Run: exiftool --duplicates -short -G1 -time:all "C:\Temp\Pictures\1.jpg"OR: exiftool --duplicates -short -G1 "-*date*" "C:\Temp\Pictures\1.jpg"
I use Linux, ext4 partition. Since CreateDate wasn't set on my image, I set the CreateDate value to use the time the file's inode was created. Windows 10 does not use inodes on NTFS partition, NTFS is proprietary and not open source. I don't know how to do this in Windows 10. Your command works.

StarGeek

%%le is a legitimate option in a date format string or %le when not part of the a date format string.

From the docs on the -w (-TextOut) option, near the very end
QuoteAll format codes may be modified by 'l' or 'u' to specify lower or upper case respectively (ie. %le for a lower case file extension).

Is this in a bat file?  If so, then see FAQ #27.

Are you using PowerShell or CMD.  PS has a lot of idiosyncrasies when it comes to common exiftool commands and its quoting rules are completely different than either CMD or Mac/Linux.  Try CMD and use double quotes instead of single quotes.

Your command works correctly here using CMD and double quotes.  The file starts as Test4.JPG with an uppercase extension and is changed to 20230825_120000.jpg after your command.
C:\>dir Y:\!temp\aa\
 Volume in drive Y is DrivePool
 Volume Serial Number is 3881-4F27

 Directory of Y:\!temp\aa

2023-08-25  07:08 AM    <DIR>          .
2023-08-25  07:08 AM    <DIR>          ..
2023-08-21  04:26 PM           445,710 Test4.JPG
               1 File(s)        445,710 bytes
               2 Dir(s)  3,812,756,606,976 bytes free

C:\>exiftool "-filename<CreateDate" -d %Y%m%d_%H%M%S%%-c.%%le Y:\!temp\aa
    1 directories scanned
    1 image files updated

C:\>dir Y:\!temp\aa\
 Volume in drive Y is DrivePool
 Volume Serial Number is 3881-4F27

 Directory of Y:\!temp\aa

2023-08-25  07:09 AM    <DIR>          .
2023-08-25  07:09 AM    <DIR>          ..
2023-08-21  04:26 PM           445,710 20230825_120000.jpg
               1 File(s)        445,710 bytes
               2 Dir(s)  3,812,756,606,976 bytes free
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

justanoob23

Quote from: ArchZu on August 25, 2023, 01:01:28 AM...

Thanks for the effort!

Quote from: StarGeek on August 25, 2023, 10:12:25 AMYour command works correctly here using CMD and double quotes.  The file starts as Test4.JPG with an uppercase extension and is changed to 20230825_120000.jpg after your command.

It indeed was double quotes that were needed. Thank you!