Facing the Exception Object is not set to an Instant


I am facing the exception while using “build the Data table” using Add Data Row. Please look into the attached Xaml. Please clarify.

Thanks in Advance.
Main.xaml (12.6 KB)
Sample101.xlsx (8.9 KB)


Have you populated DR?

Yes, I have added the Variable DR and system. data. data row type is specified.

Have you populated it?

You have an add data row then another add data row. Why? The first one correctly uses an array, what is the purpose of the second one? What are you trying to do?

I am using another method using Add Data Row. The first method is executed using Data Table_Array. Using Data Row Method is not able to Execute. Please Clarify.

You have to put data into your DR datarow variable.


To clarify

If you see the locals panel in your screenshot dr ia null…

Dr is a datarow variable you created but you did not give any value to it.

What are you trying to achieve here?



Are you reinitializing it? Because the dr variable if you see is null when you are using it


Hi Anil,

Please refer to the .xaml file

. I have assigned the values to the DR row .



I see that…can you run in debug and do step into and see if the data is getting populated or if its getting removed always


Could you please elaborate?

Main.xaml (13.3 KB)

Please look into the attached .xaml.

Hello @Harsha_S1

I hope you haven’t initialized the Datarow variable.

Can check the below post or move the Assign activity above to the Add Data Row activity.

(Initialise a data row and type - #2 by lakshman)


Hi @Harsha_S1

1.right click on the first assign activity and add a break point
2. From top panel use run in debug and run the bot
3. Once the bot pauses on the breakpoint do step into activity to move from one activity to another and on every step acheck if your dr datarow ia having data


Hi Anil,

I have tried. Still unable to clear this. Please look into the attached .xaml once and clarify with an elaborative explanation.

Thanks in Advance!!
BuildDataTableUsing_AddDataRow.xaml (10.7 KB)


I dont see any issue …It is getting added



1 Like

Thanks, Anil. Thanks for your effort.


1 Like

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