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

Screen Modification ; Shift screen to right on pressing button

Former Member
0 Likes
997

Hello All,

When user presses any button i need to shift a screen from left to right.

I tried using LOOP AT SCREEN, but there existd no option to do that.

i have embedded that screen in a frame of name "control"

on any user action i should shift the screen which appears on left to some places on the right side.

on pressing back it should come back to original place .

Please HELP.

Venkata

Hello All,

When user presses any button i need to shift a screen from left to right.

I tried using LOOP AT SCREEN, but there existd no option to do that.

i have embedded that screen in a frame of name "control"

on any user action i should shift the screen which appears on left to some places on the right side.

on pressing back it should come back to original place .

Please HELP.

Venkata

4 REPLIES 4
Read only

GauthamV
Active Contributor
0 Likes
900

Check these sample programs.

SAP_PICTURE_DEMO

RSDEMO_PICTURE_CONTROL.

Read only

Former Member
0 Likes
900

Hello ,

This doesnt suffice my need.

i need to shift the entire screen from left to right side.

I checked the programs

Please Help

Read only

0 Likes
900

1) Have two screens (sharing the PBO and PAI modules) one with the fields on the left, the other with the same fields on the right

or

2) Control where the screen is displayed by calling it as a modal dialog window using CALL SCREEN STARTING AT ... ENDING AT ....

Others???

Che Eky

Read only

Former Member
0 Likes
900

Why not use docking containers.......

Check this code....



DATA: it_sbook TYPE TABLE OF sbook,
      cont     TYPE REF TO cl_gui_docking_container,
      alv      TYPE REF TO cl_gui_alv_grid,
      wf_side  TYPE i.

START-OF-SELECTION.

  SELECT *
     FROM sbook
     INTO TABLE it_sbook
     UP TO 10 ROWS.

  CALL SCREEN 100.  "Create screen 100 with SAVE button active in PF Status

MODULE status_0100 OUTPUT.

  SET PF-STATUS 'STAT100'.

  CHECK cont IS INITIAL.

  CREATE OBJECT cont
    EXPORTING
      side                     = cl_gui_docking_container=>dock_at_right
      extension                = 600
      caption                  = 'Test'
    EXCEPTIONS
      OTHERS                  = 1.
  IF sy-subrc EQ 0.

    CALL METHOD cont->set_adjust_design
      EXPORTING
        adjust_design     = 0.

    CREATE OBJECT alv
      EXPORTING
        i_parent          = cont
      EXCEPTIONS
        OTHERS            = 1.
    IF sy-subrc EQ 0.
      CALL METHOD alv->set_table_for_first_display
        EXPORTING
          i_structure_name = 'SBOOK'
        CHANGING
          it_outtab        = it_sbook
        EXCEPTIONS
          OTHERS           = 1.
    ENDIF.
  ENDIF.
ENDMODULE.                 " STATUS_0100  OUTPUT

MODULE user_command_0100 INPUT.
  CASE sy-ucomm.
    WHEN 'SAVE'.
      CALL METHOD cont->get_docking_side
        RECEIVING
          docking_side = wf_side.

      IF wf_side EQ cl_gui_docking_container=>dock_at_right.
        CALL METHOD cont->dock_at
          EXPORTING
            side = cl_gui_docking_container=>dock_at_left.

      ELSE.
        CALL METHOD cont->dock_at
          EXPORTING
            side = cl_gui_docking_container=>dock_at_right.


      ENDIF.
  ENDCASE.

ENDMODULE.                 " USER_COMMAND_0100  INPUT