Reg - Validate field while import

schoolkidschoolkid Member Posts: 103
Hi,

I have created a XML PORT to import Customer and it works fine,this is the XML File that i import into NAV
<?xml version="1.0" encoding="UTF-16" standalone="no"?>
<Customer>
<Customer_Master>
<No></No>
<Name>micheal</Name>
<SearchName></SearchName>
<Name2>Lawson</Name2>
<Address>no 10 Dale street</Address>
<Address2>lutjensee</Address2>
<City>Dresden</City>
<Contact/>
<PhoneNo/>
<CustomerPostingGroup>CUB</CustomerPostingGroup>
<PaymentTermsCode/>
<CountryRegionCode>A</CountryRegionCode>
<BillToCustomerNo>12345</<BillToCustomerNo> (If empty i need to fill NO. generated in NAV automatically)
<FaxNo/>
<GenBusPostingGroup>NL</GenBusPostingGroup>
<PostCode>01001</PostCode>
<VATBusPostingGroup>NL</VATBusPostingGroup>
</Customer_Master>
</Customer>

If the BILLTOID has values it will import the values in the XML port but what is required is when the BillToID is empty i need to write a condition that it should take the customers no which is generated when the file is imported.

i tried to add code in the OnBeforeInsert() trigger in the xml port but still in vain.

pls suggest in which trigger can i check the condition and execute it.


Thanks in Advancr

Comments

Sign In or Register to comment.