Skip to main content

I’m working on the following process graph:

When debugging, the prepay.Record registers as null, despite the prepay having a single complete record of the invPrepayList resultset. 

Visual studio does not flag the application of the result.record.fields to the new rec fields as an error. It simply runs as though the record is null. 

Can anyone tell me what I am missing?

Since you are using a single object being returned, you can cast prepay right to APInvoice
 

foreach(APInvoice prepay in invPrepayList)

If you did a join, you would still use var, then get the item type separately, into multiple for each type. Here is an example for getting the APInvoice out of it:

foreach(var prepay in invPrepayList)
{
APInvoice invoice = prepay.GetItem<APInvoice>();

//now you can use invoice.RefNbr
}

 


Thank you, Keith. That did it. 


Reply