Ok, mine is solely used in a Custom Code Widget, I’m not prefilling a table
You may be able to build your query in the Code Widget
var InvCusts = Db.InvcHead.Where(i => i.Company == Session.CompanyID && i.Posted == true && i.OpenInvoice == true && i.CreditMemo == false && i.UnappliedCash == false && i.InvoiceBal > 1 && i.DueDate < nextsunday && Db.Customer.Any(c => c.CustNum == i.CustNum && c.NoContact == false && c.SendReminders_c == true)).Select(x => x.CustNum).Distinct().ToList();
I got the idea from