Write Range: File contains corrupted data

Working through assignment 2 second part where the bot is downloading the files and creating a data table. That part works fine, I see the files downloading, the data table is created, it’s merged with the yearly report data table and the file is deleted. Everything processes and I get to the part where you’re supposed to Write Range and I get the error that the file contains corrupted data. I tried both the Workbook and Excel Write Range activity and got the same error message.


Source: Write Range

Message: File contains corrupted data.

Exception Type: System.IO.FileFormatException

An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:
System.IO.FileFormatException: File contains corrupted data.
at UiPath.Core.Activities.ScopeActivity.OnFaulted(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom)
at System.Activities.Runtime.FaultCallbackWrapper.Invoke(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom)
at System.Activities.Runtime.FaultCallbackWrapper.FaultWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

I have no idea what any of that means or what to do to fix this. Any ideas?

Never mind. I figured it out. I was missing a \ in the file name and file path so it was running the last folder in the path into the name of the file.


This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.