Hi All,
I want to create a folder name as Currentmonth and current year, can I use below
datetime.now.ToString(“MMM-yyyy”)
Hi All,
I want to create a folder name as Currentmonth and current year, can I use below
datetime.now.ToString(“MMM-yyyy”)
Yes, you can use DateTime.Now.ToString("MMM-yyyy")
to get the current month and year in the format “MMM-yyyy”. This will give you the abbreviated name of the current month followed by the four-digit representation of the current year.
"C:\Users\rlgandu\Downloads\"+Datetime.now.ToString(“MMM-yyyy”)
→ Use Folder Exists and give the below condition and store the output in a variable say FolderExists
Path.Combine("C:\",Now.ToString("MMM yyyy"))
change the folder path accordingly within double quotes.
→ Use the below in If condition:
If
FolderExists
Then
\\Do nothing
Else
Create Folder activity and give the below syntax
Path.Combine("C:\",Now.ToString("MMM yyyy"))
End If
Regards
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.