Getting actors age from web and writing down in excel

In the screen shot I am planning to read actors age from excel and planning to write it down next to the actor column.

But there seems to be an error of OBJECT reference not set…

Hi @xyzxyz_123

Is age coming from get text and is age is string or datatable?

This error comes when variable is empty so make sure age is not empty

Drag the get text(age) above to the type into.

I dragged it but getting the same error!

Yes, age is coming from GET text and variable is data table. What do you mean by variable is empty. Default value ?

If there is no row in a datatable it is considered as empty, can you put message box above write range and put age.rows.count.tostring and show as how many rows age datatable has.

Sorry, I did not understand. When you mean no rows in data table. Did you mean no rows in excel from which I am trying to read data?

From what I see you read a column which doesn’t provide a datatable, and then you use get text which again doesn’t provide a datatable output then where is this age datatable comes from .

Yes, you are right! Read column data variable is System.Collections.Generic.IE while get text variable type is data table. What should I do now?

I would use read range instead of read column and use for each row instead of for each and update age in datatable iside for each row and write the range once it comes out of the loop

If it still not helps I will provide a sample workflow.

HI , I tried as you said but still facing the same error!

both the variables are of datatable type

Please try this sample workflow,

sample.xaml (10.9 KB)

Hi @xyzxyz_123

Is it working for you?