Options

Employee Portal - Field Validation

r44712r44712 Member Posts: 40
edited 2009-01-19 in Navision e-Commerce
Hi,

I hope this is a simple question, but how do you validate field values entered in Employee Portal?

I have the following code for the "Bill-to Customer No." in the Job record (within the Codeunit 6824 "EP Modify Head Data Mgt.":
...
...
...
  EncodeXML.AddFieldToValidationDoc(XMLDocValField,Job.FIELDNO("Bill-to Customer No."));


  DecodeXML.ModifyRecord(XMLDocInHead,HeadRecordRef,XMLDocValField,DATABASE::Job,
    TRUE,FALSE,AdditionalValues[1],AdditionalValues[2]);

  //Validations....
  HeadFieldRef := HeadRecordRef.FIELD(Job.FIELDNO("Bill-to Customer No."));
  Customer.GET(HeadFieldRef.VALUE);
  HeadFieldRef.VALIDATE(Customer."No.");


  HeadRecordRef.MODIFY(TRUE);
...
...
...

What is it that is not right with this code (Validate.... section)?


Many thanks in advance.
Sign In or Register to comment.