Skip to main content
Question

Events ovveride

  • April 30, 2026
  • 2 replies
  • 16 views

mos11
Freshman I
Forum|alt.badge.img

 

Maybe this question is very simple, but I can’t find an answer about it.

I know that if I write an event like this and do not call baseMethod inside the body, the base method code will not execute. If I want the base code to run, I must explicitly call it. This part is clear to me.

​​​​​​​protected void _(Events.RowSelected<ARInvoice> e, PXRowSelected baseMethod) { }

When I write the event like this, I tested that the base methods are called automatically:

protected void _(Events.RowSelected<ARInvoice> e) { }

But I do not understand why this happens. I tried to find something in the documentation.

In the 2026 R1 Developer Guide, I found information that seems to contradict what I observed during testing.
 

In T210, I found events written without baseMethod, so I assume that writing them this way is valid.

However, there should be documentation somewhere explaining this behavior, and I do not understand what is written in the Developer Guide regarding this case.


Could you provide a general explanation of how this works, and is there any place where this behavior is documented correctly and in detail?
 

2 replies

Forum|alt.badge.img+1
  • Varsity III
  • April 30, 2026

Without baseMethod - event subscription → base runs automatically

With baseMethod - override → you must call base manually


Naveen Boga
Captain II
Forum|alt.badge.img+20
  • Captain II
  • April 30, 2026

@mos11 

Signature 1:  Override (replaces the base):

protected void _(Events.RowSelected<ARInvoice> e, PXRowSelected baseMethod) { }

You are taking full control of the process. The baseMethod contains all the existing logic that was already there. If you don’t call  baseMethod(e.Cache, e.Args), that existing logic will not run.
So it’s up to you whether to run it or skip it.

 

Signature 2 :  Append

protected void _(Events.RowSelected<ARInvoice> e) { }

Your method is added to the list of existing handlers.
It runs together with them, not instead of them.
You don’t control the whole process, so there’s nothing you need to call or skip ,  everything runs automatically.

For most customization work, we do generally,  use the no-parameter signature unless you specifically need to suppress or conditionally skip existing base logic. The baseMethod pattern is powerful but risky,  if you forget to call it, you can silently break base Acumatica behavior in ways that are hard to debug.

 

Hope this info helps!