Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Add a date stamp to a file name or replace an existing one
ResourceFunction["FileNameWithDate"][filename] returns a new filename string with a date stamp inserted before the file extension. |
Add a date stamp to a file name:
In[1]:= |
|
Out[1]= |
|
The input can be a File object:
In[2]:= |
|
Out[2]= |
|
Replace a date stamp with a new one:
In[3]:= |
|
Out[3]= |
|
The input can contain directory information:
In[4]:= |
|
Out[4]= |
|
The filename does not need to have a file type:
In[5]:= |
|
Out[5]= |
|
The input filename can represent a directory:
In[6]:= |
|
Out[6]= |
|
Create a copy of a file with a date-stamped filename before editing the original file:
In[7]:= |
|
Out[7]= |
|
The input must not be an empty string:
In[8]:= |
|
Out[8]= |
|
This work is licensed under a Creative Commons Attribution 4.0 International License