Hello everyone. I am new to C# ( moving from E9 to E10) I am having a hard time moving data from my part master to the QuoteDtl Screen, and was looking for a little help. Here is what I have as of now.
foreach (var tempQuoteDtl in ttQuoteDtl.Where(qd => qd.Updated() || qd.Added()))
{
var part = (from p in Db.Part.With(LockHint.UpdLock) where p.Company == tempQuoteDtl.Company && p.PartNum == tempQuoteDtl.PartNum select p).FirstOrDefault();
if(part!=null)
{
tempQuoteDtl.Number01 = Part.UserInteger1;
Db.Validate();
}
}
Hi Rick,
That code should work (though you donât need the Db.Validate() bit since you are just writing to the tempQuoteDtl or (tt) table. When are you triggering this BPM?
If its Post Processing then it wonât work because you are writing to the TT Table youâd need to do a LookUp of the Actual Db.QuoteDtl record and then update it.
-Jose
This is processing during Pre-Processing. When I had the data conversion form E9 It brought over the field âNumber01â is the system having a hard time with this? Here is the Error I am getting.
Error CS1061: âErp.Tablesets.QuoteDtlRowâ does not contain a definition for âNumber01â and no extension method âNumber01â accepting a first argument of type âErp.Tablesets.QuoteDtlRowâ could be found (are you missing a using directive or an assembly reference?) [Update.Pre.Seq.cs(79,17)]
Error CS0120: An object reference is required for the non-static field, method, or property âErp.Tables.Part.UserInteger1.getâ [Update.Pre.Seq.cs(79,28)]
Error CS0120: An object reference is required for the non-static field, method, or property âErp.Tables.Part.UserInteger1.getâ [Update.Pre.Seq.cs(79,48)]
Of course I use a lot of these fields, but I feel If I can get one right it will help with the rest.
the struggle is real! I had to learn it quickly when uplifting from E9. Still learning, learning learning⌠Toot Joseâs horn by marking his answer as solved