cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Screen Personas: Expand/Collapse of Header and Item details in PO

0 Kudos

Hello Experts,

Has anyone got experience with enjoy transactions like ME23N (Purchase order display).

I am planning to display some data from all the three selection like Header, Item and Item details selections (One Tab from each of this selections).

When I am Expanding the Header selection the Item details selections is Collapsed automatically and visa-vasa How I can stop this behavior.

Please guide me, How I can achieve data from all the 3 selection .

I have maintain the entries in Main Control ID Overwrite Logic for ME21N,ME22N and ME23N.

ME21N     SAPLMEGUI     0014

^ses\[0\]/wnd\[0\]/usrUSRAREA/subcntSUB0SAPLMEGUI\w+$

ses[0]/wnd[0]/usrUSRAREA/subcntSUB0SAPLMEGUI__COMMON__

ME22N     SAPLMEGUI     0014

^ses\[0\]/wnd\[0\]/usrUSRAREA/subcntSUB0SAPLMEGUI\w+$

ses[0]/wnd[0]/usrUSRAREA/subcntSUB0SAPLMEGUI__COMMON__

ME23N     SAPLMEGUI     0014

^ses\[0\]/wnd\[0\]/usrUSRAREA/subcntSUB0SAPLMEGUI\w+$

ses[0]/wnd[0]/usrUSRAREA/subcntSUB0SAPLMEGUI__COMMON__

Please advice me on how to achieve this.

Regards,

Venky.

    

Accepted Solutions (1)

Accepted Solutions (1)

chinthan_yajamaan
Active Contributor
0 Kudos

Hi Venky,

Enjoy transactions are tricky because of their dynamic behavior. The expand/collapse are decided based on the screen area available for display by the program dynamically. If you have a tab which is tall in header area, then selecting that will collapse item or item details area which can lead to tab caching failure if any (control does not exists error). So I would advise you to design your screens differently.

If you still need to have all expanded, then you can try fullscreen mode and higher resolution and having a script button in oncreatehandler to expand header, item, item details. But as I said before, if screen size is not sufficient, it would lead to collapsing of one of the areas.

Thanks

Chinthan

0 Kudos

Hi Chinthan,


Thanks for quick reply, The issues remains same, Please check below my reply.


Thanks & Regards,

Venky.

Answers (3)

Answers (3)

former_member195167
Participant
0 Kudos

I solved it for ME51N by scripting the button this way:

session.findById("wnd[0]/tbar[0]/okcd").text = " ME51N";

session.findById("wnd[0]").sendVKey(0);

session.utils.changeFlavor("005056BA7C3A1ED496C8EC82C3D6F123");

session.findById("wnd[0]/tbar[0]/okcd").text = " METOGGON1";

session.findById("wnd[0]").sendVKey(0);

session.findById("wnd[0]/tbar[0]/okcd").text = " METOGGON2";

session.findById("wnd[0]").sendVKey(0);

session.findById("wnd[0]/tbar[0]/okcd").text = " METOGGON3";

session.findById("wnd[0]").sendVKey(0);

You can get the codes from transaction SE41 by keying in the program name.

0 Kudos

HI Chinthan & Neli Ward,

Thanks for valuable input, I have tried above all the point, but issue remains same.

  1. I have ungroup all the containers and drag out all the UI elements and placed outside containers.
  2. To avoid the space issue, I have remove the item selection (Now I am trying to display only three fields in "Header" selection and one table in "Item details" selection  )
  3. Reduced the height and wide all the elements.

After doing all above 3 points also the behavior is same,

@Chinthan - "Having a script button in oncreatehandler to expand header, item, and item details"

I am not able to figure out point "script button in oncreatehandler to expand header", Could you please explain with more details

Please find the screen shots below.  


In the below table "Item Details is Collapsed"


When click on the "Item Details" Expand/Collapse button the screen changes as shown below.

chinthan_yajamaan
Active Contributor
0 Kudos

Hi Venky,

1. Add a script button in edit mode

2. Add "Push" action on item and item details buttons in script button.

3. Copy control id for script button from properties window (left click and value will be copied to clipboard)

4. Select UserArea control on screen (main area below toolbar which holds all the other screen elements)

5. Go to property window and scroll to OnCreateHandler property and paste the script button id copied before.

6. Save and Exit

Now everytime the screen loads or refreshes, this script button gets invoked to perform push action on item and item details buttons.

Thanks

Chinthan

former_member195167
Participant
0 Kudos

Hi Chinthan,

what is the equivalent of OnCreateHandler in Personas 3.0?

Thanks!

chinthan_yajamaan
Active Contributor
0 Kudos

Hi Saud,

Please refer to GuiMainWindow events Available Events for Scripting - SAP Imagineering - SCN Wiki

Thanks

Chinthan

Former Member
0 Kudos

Yes this is possible, we've done it with ME51N which is similar to ME23N

Thing is, with these enjoy transactions, there are containers within containers within containers.

The trick is to ungroup all the containers and drag out all the UI elements you need onto the screen and hide the rest!

Then you can get all 3 sections on the screen at the same time... see below

0 Kudos

Hi Neli Ward,


Thanks for quick reply, The issues remains same, Please check below my reply.


Thanks & Regards,

Venky.

p_soobhany
Participant
0 Kudos

Hello Neil Ward,

I am currently doing the same thing in ME21N and I have followed your suggestion.

However, I am loosing all the contents of my header. I have removed 3 fields from the header and placed them outside the container and then the container has been hidden.

Any suggestion on how to solve this problem?

Thanks

Parvez