Academy Foundation Training Lesson 9 - Excel and Datatables Runtime Exception being thrown

So I think I solved my own problem. According to some on the forums, UiPath Runtime is executing too fast for initializing multiple instances of Excel in sequence. Adding a delay seems to work, see this post:

Instead of implementing Write Line I add a Delay Activity from the Workflow.Control activities set. If I start fresh I can get it execute without exceptions at Delay.Misc.Duration = TimeSpan.FromMilliseconds(050).
If I execute it again without deleting the newly created spreadsheet, it throws a runtime error with Write Range. If I increase TimeSpan.FromMilliseconds to (100) or (250), it seems to not complain–even when overwriting the existing created file! :grinning:

1 Like