Trying to Copy data from OrderDtl.QuoteNum to UD field OrderHed.QuoteNum_c and show on Order Entry Screen on load

,

// Field Filled?  Based on you saying they're going to free form type in there this should be a nvarchar(x) field so compare it with a known set string  of "NotFilled" otherwise assume field is filled.
this.bFieldNotFilled=((Db.OrderHed.Where( r=>r.Company==Session.CompanyID && r.OrderNum == this.iOrderNum ).Select(r=>r.QuoteNum_c).FirstOrDefault() ?? "Not Filled")=="Not Filled"); 

I just define the variables in the DD for debug purpose and readability my mistake on the above I forgot the OrderHed table is not part of the recordset. This should get you a boolean variable you can check against.

Add these in above the condition check:

EDIT: *Note to above code block, you will not need to grab the this.iOrderNum in the setter block as the value has been set to check the OrderHed table field for data.