How can we add data row in data table in UI path in C#

In the Vb we are adding Data Row like {name, age}.
So, i just wanted to know that how can we do that same thing in the c#.

Currently, I am getting the below exception while adding the data row.

19.7.0+Branch.master.Sha.8c253d13718eed5c7db27daef6facd1fe1b0d067

Message: Compilation failures occurred:

; expected	Invalid expression term ','	; expected	; expected	Invalid expression term ','	; expected	; expected	Invalid expression term '{'	; expected	; expected	Invalid expression term ','	; expected	; expected	Invalid expression term ','	; expected	; expected

Complete results are contained in the Data property of this exception. Please correct the errors in the source and retry the Load.

Exception Type: System.InvalidOperationException

RemoteException wrapping System.InvalidOperationException: Compilation failures occurred:

; expected	Invalid expression term ','	; expected	; expected	Invalid expression term ','	; expected	; expected	Invalid expression term '{'	; expected	; expected	Invalid expression term ','	; expected	; expected	Invalid expression term ','	; expected	; expected

Complete results are contained in the Data property of this exception. Please correct the errors in the source and retry the Load.
at System.Activities.XamlIntegration.ActivityXamlServices.Compile(IDynamicActivity dynamicActivity, LocationReferenceEnvironment environment)
at System.Activities.XamlIntegration.ActivityXamlServices.Load(XamlReader xamlReader, ActivityXamlServicesSettings settings)
at System.Activities.XamlIntegration.ActivityXamlServices.Load(XmlReader xmlReader, ActivityXamlServicesSettings settings)
at System.Activities.XamlIntegration.ActivityXamlServices.Load(Stream stream, ActivityXamlServicesSettings settings)
at UiPath.Executor.WorkflowRuntime.Load(String workflowFile)
at UiPath.Executor.RobotRunner.InitWorkflowApplication()
at UiPath.Executor.RobotRunner.d__69.MoveNext()

2 Likes

I am getting also same error. Because of c# has experimental feature of uipath so might be some issue in datatable activity.
@loginerror @Pablito guys please clear this point

Thanks

1 Like

Hi @Ritesh123

Welcome to our UiPath Forum! :slight_smile:

Could you show us how your code looks like in Studio?

Hi @loginerror

Please find attached image of data row where i am getting the issue.

Hi @Ritesh123

Could you make sure your activity packages are updated to the latest version 19.7.0 (both System and UiAutomation)? It seems to be working on my end.

1 Like

Need to check if there a syntax related issue: please verify this two demos which may have your answer you are looking for:

and