Skip to main content
Solved

Not able to load data into custom field in Customer Details(AR402000) screen

  • February 16, 2022
  • 5 replies
  • 223 views

Hello,

We have to load project id into customer details inquiry screen using custom field.

We have added a new custom field on customer details screen and not able to assign the project id value of the invoice. It is always returning an empty value even it is assigned in the code.

ā†’ Extended the graph and overided the Document() view delegate.

ā†’ In the debug, the value is assinging but it is not showing in the screen and I tried to add hardcoded value but still it is not working

 

ā†’ I have used another method from view delegate to assign the value but still same issue.

 

I have attached the cusotmization package with the above code. Can anyone let me know the issue in this code or how can we load project id to customer details grid section.

Thanks in advance.

Best answer by Naveen Boga

Hi @ssamboju12  Iā€™m not sure why it is not working, can you please check with ARDocumentResult_UsrASGProjectID_FieldSelecting event and confirm?

View original
Did this topic help you find an answer to your question?

5 replies

Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • 3398 replies
  • February 16, 2022

Hi @ssamboju12  Have you tried with Row_Updated event instead of view delegate?

According to me it should work with Row_Updated event. Please verify.

 


  • Author
  • Freshman II
  • 14 replies
  • February 16, 2022

@Naveen B  Thanks for the response.

Row_Updated event is also not working.

 

public class ARDocumentEnq_Extension : PXGraphExtension<ARDocumentEnq>
    {

        public virtual void ARDocumentResult_RowUpdated(PXCache cache, PXRowUpdatedEventArgs e)
        {
            ARDocumentResult header = e.Row as ARDocumentResult;
            if (header == null) return;
            ARDocumentResultExt resext = header.GetExtension<ARDocumentResultExt>();
            ARInvoice projobj = PXSelect<ARInvoice,
                Where<ARInvoice.docType, Equal<Required<ARInvoice.docType>>,
                And<ARInvoice.refNbr, Equal<Required<ARInvoice.refNbr>>>>>.Select(Base, header.DocType, header.RefNbr);
            if (projobj != null)
            {
                resext.UsrASGProjectID = projobj.ProjectID;
            }

        }
}

 


Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • 3398 replies
  • Answer
  • February 16, 2022

Hi @ssamboju12  Iā€™m not sure why it is not working, can you please check with ARDocumentResult_UsrASGProjectID_FieldSelecting event and confirm?


  • Author
  • Freshman II
  • 14 replies
  • February 17, 2022

Hello @Naveen B 

Fieldselecting event worked finally. 

Thanks for the suggestion.

 


Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • 3398 replies
  • February 17, 2022

@ssamboju12  Great :) Thanks for the update. 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings