Write csv with date time stamp

please kindly assist with this string. im trying to action the write csv activity and add a date time stamp after the filename in the specific location

“C:\Users\theuser\Desktop\Robotics\Chrome\SConfig2.0\functionlibrary\00_data+“dtout_cart”+DateTime.Now().ToString(“ddMMyyhhmmss”)+”.csv"

it keeps complaining about “end of statement expected”

1 Like

hey Nyx,

First thing : Excel will not accept special characters present in date time like(:, /, , etc) please check this manually, whether your name is acceptable to Excel?

Second thing: end of statement expected

this error is due to string which you are passing it have some issue, if it is possible then you should share your xaml

regards
Aditya

Hi @aditya.prakash

I have the following:

image

Hey Nyx,

use this: “C:\Users\theuser\Desktop\Robotics\Chrome\SConfig2.0\functionlibrary\00_data”+“dtout_cart”+DateTime.Now().ToString(“ddMMyyhhmmss”)+”.csv"

actually you missed one closing inverted comma (")

regards
Aditya

2 Likes

@aditya.prakash -thank you so much