cancel
Showing results for 
Search instead for 
Did you mean: 

Message in default logic

0 Kudos

Hi,

I am doing currency conversion in the default logic using UJ_CUSTOM_LOGIC BADI.

When I run the "currency conversion logic" using package, I can display the message using the below command and I can see the output in Status.

  CL_UJK_LOGGER=>LOG( I_OBJECT = L_LOG ).

Example: 'Rates not found in RATE Application' etc. ( Any custom message).

But when I am running it in the default logic. I can't see the output anywhere. Only I get the message that 1 records submitted.

If the RATE application does not contain corresponding Exchange Rate, I can't see the message that 'Rates not found in RATE Application" etc.

Any idea, about how to generate messages in default logic or where to see the output messages.

Accepted Solutions (1)

Accepted Solutions (1)

former_member186338
Active Contributor
0 Kudos

Hi Archit,

If you rewrite you code to be inside write back BADI (same effect as usage of default logic) then you will be able to pass messages to Excel popup.

B.R. Vadim

0 Kudos

Hi Vadim,

Yes you are correct, I can do it that way. However I want to avoid that since there is already one logic written in write back and I don't want to make write back very complicated.

I am sure there must be some way to popup the message in default logic too..lets wait for others to reply.

Regards,

Archit

former_member186338
Active Contributor
0 Kudos

Hi Archit,

I am still recommending you to move code to the write back badi, because the workaround will be much more complicated: you will have to store the messages and rejected members generated by your custom logic somewhere, and then to add some code in write back to get this stored data and to append it to the records generated by write back badi itself...

There is no way to directly put messages from custom logic to Excel popup.

And there is some additional benefit for replacing default.lgf by write back badi: only really changed members will be processed, not a Cartesian result of all dimension members in scope of the default logic.

B.R. Vadim

former_member200327
Active Contributor
0 Kudos

Hi Archit,

You can try 2 methods: utilize Validation or raise an exception CX_UJ_CUSTOM_LOGIC. Both will pop-up a message box and stop data from being written back to the cube.

Gersh

former_member186338
Active Contributor
0 Kudos

Hi Gersh,

One question about raise of exception: we tested this method but achieved only full stop of script execution. Can you provide some examples?

B.R. Vadim

P.S. The idea with Validation requires that the logic in custom logic BADI have to be somehow duplicated in Validation BADI...

Answers (0)