SAP for Utilities Discussions
Connect with fellow SAP users to share best practices, troubleshoot challenges, and collaborate on building a sustainable energy future. Join the discussion.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to call an FQEVENT at later stage?

ricky_shaw
Contributor
0 Kudos
572

Hello Experts,

I have this std FQevent R437 that is called at line#141 in FM : ISU_INV_UNIT_ACTION. This R437 suits my requirement as i need to assign invoice amount to xy_invoice_param-outsort_amt.

But i want it to be called after line# 954 as i will get new invoice amount and after that i can assign it to the parameter xy_invoice_param.

Surprisingly i see that the event R436 is called quite later (than R437) which is at Line 1158.

So how to call an FQEVENT at later stage?

6 REPLIES 6

ricky_shaw
Contributor
0 Kudos
296

Experts,

Can someone answer this? I can see event R419 getting triggered but i don't know what is it for. It has only import parameters.

I want to change the out sorted amount in X_INVOICE_PARAM.

ricky_shaw
Contributor
0 Kudos
296

I think i found a solution. It's working i.e doing the necessary updated if i call this R437 in some other FQ event .

Can someone tell me if this permissible & does not lead to any problems?

0 Kudos
296

Can any one please tell me if this is wrong or right?

Sandra_Rossi
Active Contributor
0 Kudos
296

Defining custom code behind an FQEVENTS event is like calling a function module at a user exit i.e. standard code is like this:

" so-called event R437
CALL FUNCTION 'registered function module name for event R437' ...

...

" so-called event R436
CALL FUNCTION 'registered function module name for event R436' ...

SAP don't forbid your custom code to do that in any of your custom function modules:

FUNCTION <registered function module name for event R437>.
...
CALL FUNCTION 'registered function module name for event R436' ...
...
ENDFUNCTION.

harald_lesche-holzbecher
Product and Topic Expert
Product and Topic Expert
296

Hi,

first of all I think that R437 doesn't suit your requirement as the documentation says:

"Currently, you can only change the posting date (BUDAT) and document date (BLDAT) for the invoicing parameters."

Regarding "if i call this R437 in some other FQ event":

Why do you want to call R437 from some other event, if this other event allows to change the out sorted amount in X_INVOICE_PARAM?

Why don't you then change it there directly?

ricky_shaw
Contributor
0 Kudos
296

Hi,

R437 is just assigning the contents in x_invoice_unit into X_INVOICE_PARAM out sort structure.

R437 suits my requirement.. but it is getting called way before the new invoice mount is getting called.

Example: I mean if R437 is called at line 10 & the new invoice calc is done at line 100. There is other FQevent 582 which is called at line 110 & is allowing the call to R437 with assignment / changing of parameters.

I see its working fine w/o any dumps.

Please suggest.