Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
Showing results for 
Search instead for 
Did you mean: 

Not to able to capture the value of SY-UCOMM correctly

Former Member
0 Kudos

Hi All,

I have designed a table control which shows me the list of component commodities for a given commodity .

In this screen which contains the table control, the print button at the top of the screen has been enabled.

When I click on the print button, it takes me to an Alv list display screen which gives you a list of component commodities for a given commodity.

When i press /h i.e. get into debugging mode and press back on this screen that contains the alv list display mode,the sy-ucomm field contains the value &f03.

But when it comes to the pbo of the screen from where I gave the print command, the sy-ucomm field value is blank.

When I do a step-by-step debug upto the pbo of the screen from which I gave the print command,I get the sy-ucomm value as &F03,but if I make a direct execution upto the pbo of the screen from which I gave the print command,I get the sy-ucomm field value as blank.

Please could anyone help me out with this and tell me the reason why this is happening.


Sushanth H.S.


Active Contributor
0 Kudos

Hi Sushant,

There must be some thing wrong with debugging/direct execution. It wont behave differently when u debug and directly execute. Are u executing for same set of conditions. I am sure that the flow logic must be different. When u execute directly ucomm must be cleared some where. Also dont use sy-ucomm directly. Take it in to some variable in the PAI of one screen and use it in PBO of other screen. There might be many things happening in between which will change ur sy-ucomm value.

Hope it is clear.



0 Kudos

Hi Vinod,

I am also completely surprised that the sy-subrc value is different when you do a step-by-step debugging(press F5) and when you do a direct debugging (press F6 or F8 ).

It will not be possible for me to capture the value of SY-SUBRC in a different variable during PAI as the PAI is being triggered from the back-button of the standard ALV report.

Just let me know if I have to send the code to you.


Sushanth H.S.