Problem with Assigment 2 - Advanced Training

I have error:
Merge data table : Object reference not set to an instance of an object.
What I need to do?

Hi @Olegik_Super,

The MergeDataTable activty is trying to access a member of a reference type variable that is set to null.

Check your code, maybe some of the dataTables has not been initialized.


1 Like

What do you mean ?
I created the variable “dt_YearlyReport” with the type DataTable
What should I have done?

This happens when you have no report available hence your datatable is empty.
So best practice is to build a default datatable before your read the downloaded report with same column name . So when you merge dataTable you have at lease default datatable value in it.
Hence there won’t be any error.

1 Like

can u plz give some demo, how to do it…