Hi,
I’m having a couple of issues while trying to count the number of times a keyword shows in a data table.
Initially, I’m looping through a datatable to get the initial count - that works fine. Using the same dt, I’d like to count the number of times a keyword shows within a specific column.
(The column name has been defined within the ‘Get row item’ read from an excel doc)
I’ve tried to set this condition within an if statement:
Then attempt to get the count of those rows which meet that condition however, I receive this error: Object reference not set to an instance of an object.
I’ve also tried a select statement, but again I’m receiving errors. Can someone point out if I’m missing something / a simpler way to achieve this?
You can remove “=True” from your condition. Also the error you received might mean you used a variable that’s empty. Do you have the If condition inside a ForEach row loop? That way row has data.
Thanks, I no longer receive the error message any longer, but I’m still not able to get the total count.
No error is thrown, but it doesn’t seem to meet the condition when I step through in debug mode.