Append Line: One or more errors occurred

Hi,

I am trying to create log file under Logs folder for my project for each day. I have used Assign activity to create a variable for getting todays date(TodaysDate). When I try to concatenate the variable in write to filename in Append line (“Logs\ProjectName_Log_” +TodaysDate+“.txt”). It throws run time error like “Append Line: One or more errors occurred.”. Why do I get this error?. Thanks in Advance.

  • Indira

@Ikandhan

Would it be possible to have you upload a screenshot of your assign and append line activities?

Its possible it is trying to save it formatted as “MM/DD/YYYY”, which likely won’t work as “/” is problematic for a file name. If it is setup as such, you can change the format to “MM_DD_YYY”, or similar, and the error should fix.

Get rid of TodaysDate. Just use Now.ToString(“MMddyyyy”) or whatever format you want for the date. Just don’t use special characters like / in the string format because they’re invalid for filenames.

@BenZee @postwick

Thank you for your quick reply. It really helped me to fix the error. Thanks again.