Calculate Client Security Hash assign fault


#1

I think I’m getting close on this but I’m having trouble assigning my data table from my Extract Work Items workflow to the variable in my main. I have in_WIList as a datatable and WIs as a DataRow[] but when I try to assign I get an error. Error


Assignment 1 - assign fault
#2

Hi,

Everything inside the parenthesis(the filter expression) is supposed to be a string (“red text”).
It looks you have the right syntax… hmm. Try pasting this:

in_WIList.Select(“Type=‘WI5’ AND Status=‘Open’”)


#3

@nbjerke

Still no go. I’m getting “System error at initialization: Cannot find column [‘WI5’]. at Source: System.Data” in the output pane, which doesn’t make sense with that syntax.


#4

Ok. I think the problem is where you are selecting from, on your WIList. You cannot use the select function on a list, but only on a datable.

As you can see from the walkthrough document


#5

I do have it as a datatable.

I can use a message box with in_WIList(0)(1).tostring and it will show me the correct first value so I know the table is getting populated just before the assign. I just don’t understand why it’s looking for WI5 as a column. :frowning:


#6

Hi @Will_Tyler,

What is the variable type of in_WIList.

Adding a screenshot for your reference here.

image

TransactionData is a DataTable variable and lsWorkItems is of type List of DataRow.

*If you declare lsWorkItems as DataRow[] then you can avoid using .ToList in assign.

Regards,
Rahamat


#7

I found the problem. When I did my data scraping I didn’t select the headers. :tired_face: I redid my scrape and now it works.


#8

If you get the error about converting DataRow to Datatable like so:

Then just modify the data type of your WiList to Array Of with System.Data.DataRow

Now the validation error will go away :slight_smile: