{"id":13972,"date":"2021-12-14T05:45:56","date_gmt":"2021-12-14T05:45:56","guid":{"rendered":"https:\/\/lgildv5i97.onrocket.site\/answers\/?post_type=question&#038;p=13972"},"modified":"2021-12-14T05:46:27","modified_gmt":"2021-12-14T05:46:27","slug":"forfiles-how-to-parse-fdate-and-use-that-as-part-of-name","status":"publish","type":"question","link":"https:\/\/computing.net\/answers\/programming\/forfiles-how-to-parse-fdate-and-use-that-as-part-of-name\/31074.html","title":{"rendered":"Forfiles. How To Parse @fdate And Use That As Part Of Name"},"content":{"rendered":"<p>I need to store these with the date in the filenames. They are different formats so, I think the best thing would be to store the filename with the date modified @fdate but it&#8217;s in a wierd format. Help?<\/p>\n<p>forfiles -p &#8220;D:\\path\\logs&#8221; \/D -10 \/C &#8220;cmd \/c if @isdir==FALSE ^0x22C:\\Program^ Files\\7-Zip\\7z.exe^0x22 a -tzip ^0x22D:\\path\\logs\\Archive\\%today%_archive.zip^0x22 @path -sdel&#8221;<\/p>\n<p>forfiles \/P &#8220;D:\\path\\logs\\Archive&#8221; \/D -20 \/C &#8220;cmd \/c if @isdir==FALSE del \/q @path&#8221;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"inline_featured_image":false,"iawp_total_views":55},"question-category":[55],"question_tags":[],"class_list":["post-13972","question","type-question","status-publish","hentry","question-category-programming"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question\/13972","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question"}],"about":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/types\/question"}],"author":[{"embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/comments?post=13972"}],"wp:attachment":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/media?parent=13972"}],"wp:term":[{"taxonomy":"question-category","embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question-category?post=13972"},{"taxonomy":"question_tags","embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question_tags?post=13972"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}