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

Changing GUI status dynamically

Former Member
0 Likes
2,497

Hi All,

I want to change the GUI Status - buttons dynamically. ( Not changing the gui status bar . Just enabling and disabling buttons of the application toolbar )

I want to do this dynamically -

1. Without calling the screen again.

2. Without creating another GUI status.

Pls let me know if there is any of such possiblity,

Thanks & Regards,

Sunil G

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,880

Hi Vinod,

For that, i have to call the screen again for PBO to be triggered.

As i mentioned earlier, i shudnot call the screen.

Is it possible without calling the screen again.

Thanks,

Sunil G

9 REPLIES 9
Read only

former_member196299
Active Contributor
0 Likes
1,880

Hi ,

Can you please elaborate your requirement ?

Regards,

Ranjita

Read only

Former Member
0 Likes
1,880

Hi Ranjita,

I have a screen with a gui status.

It has 3 buttons on the application toolbar. Initially when the screen is called 2 buttons shud be disabled. Later on with user actions , those buttons shud be again enabled.

For EX : View , Delete , Modify are the three buttons. Initially only view will be there later on , Modify and delete will be added to the screen with some user interaction .

All this happens on the same screen and same GUI Status.

So , i have to enable the buttons in PAI only. ( without using call screen ).

Thanks,

Sunil G

PS: Im new to ABAP. Recently got trained. I ve been asked this question. Tried diff things which dint work.

Read only

0 Likes
1,880

Hi

Please refer to the documentation of SET PF-STATUS ... EXCLUDING itab.

Regards,

Gerd Rother

Read only

0 Likes
1,880

Hi,

Set a flag variable in PAI of the screen based on the user actions. Now in PBO of the screen, set pf status excluding itab.

Populate itab based on flag variable. What is the next screen mentioned in the screen attributes?

Thanks,

Vinod.

Read only

0 Likes
1,880

Hi Cricsun ,

In screen programming , anytime some uner interaction happens on the screen the PAI of that screen triggers and after that the PBO automatically gets called before you see the screen again .

According to your requirement , you can use logic in PBO itself to enable or disable the buttons and theer is no need to call the screen for the second time .

Write back if you have further questions .

Regards,

Ranjita

Read only

Former Member
0 Likes
1,881

Hi Vinod,

For that, i have to call the screen again for PBO to be triggered.

As i mentioned earlier, i shudnot call the screen.

Is it possible without calling the screen again.

Thanks,

Sunil G

Read only

0 Likes
1,880

For that, i have to call the screen again for PBO to be triggered.

You don't have to call the screen again. In screen attributes there is a box Next screen . Fill that with the same screen number i..e. 100. So whenever the PAI is triggered, the PBO of same screen will be called automatically and it will be redisplayed (not recalled). So actually no your further action required here instead of the one above.

Then just proceed as above suggested (SET PF-STATUS ... EXCLUDING).

Regards

Marcin

Read only

former_member196299
Active Contributor
0 Likes
1,880

Hi Cricsun,

It is not possible to enable/disable buttons in the appl tool bar without calling the screen again .

Regards,

Ranjita

Read only

Former Member
0 Likes
1,880

Thanks All,

Problem solved.

Regards,

Sunil G.