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

Problem with POPUP_WITH_TABLE_DISPLAY

Former Member
0 Likes
2,788

Hi,

Iam using fn . module POPUP_WITH_TABLE_DISPLAY for my requirement where Iam displaying my internal table data on the screen.

FUNCTION popup_with_table_display.

*"----


""Local interface:

*" IMPORTING

*" VALUE(ENDPOS_COL) TYPE INT4

*" VALUE(ENDPOS_ROW) TYPE INT4

*" VALUE(STARTPOS_COL) TYPE INT4

*" VALUE(STARTPOS_ROW) TYPE INT4

*" VALUE(TITLETEXT) TYPE CHAR80

*" EXPORTING

*" VALUE(CHOISE) LIKE SY-TABIX

*" TABLES

*" VALUETAB

*" EXCEPTIONS

*" BREAK_OFF

*"----


I have 2 issues.

1. 3 fields are displayed on the screen. Even, if I select 1st row on the screen, Iam getting CHOISE vaues as '3' and so on.

Why its happening? What may b the problem?

2. CALL FUNCTION 'POPUP_WITH_TABLE DISPLAY'

EXPORTING

ENDPOS_COL = 40

ENDPOS_ROW = 12

STARTPOS_COL = 20

STARTPOS_ROW = 5

TITLETEXT = 'Demo'

IMPORTING

CHOISE = choice

TABLES

VALUETAB = it_Sd

EXCEPTIONS

BREAK_OFF = 1

OTHERS = 2.

Now, 5 records are displaying on the screen with above end positions and start positions.

If I have 50 records, does all of them get displayed on the screen.

If 'NO', what can I do to see all the data in the internal table on screen irrespective of no. of records?

Thanks,

Shivaa........

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,415

Hello Shiva,

This FM works like a charm for me, try out the following code


Data : Begin Of tOptions Occurs 50 ,
          VTEXT(10),
       End Of tOptions.

Data : cChoice Like SY-TABIX.
   Clear   tOptions.
   Refresh tOptions.
   Do 50 Times.
      tOptions-VTEXT = sy-Index.
      Append tOptions.
   EndDo.

Perform DisplayOptions.
*
Form DisplayOptions.
   Clear : cChoice.
   Call Function 'POPUP_WITH_TABLE_DISPLAY'
     Exporting
       EndPOS_Col   = 130
       EndPOS_Row   = 15
       StartPos_Col = 50
       StartPos_Row = 11
       TitleText    = 'Select processing option...'
    Importing
      Choise        = cChoice
    Tables
      ValueTab      = tOptions
   Exceptions
     Break_Off      = 1
     Others         = 2.
   Read Table tOptions
        Index cChoice.
   Write cChoice.
EndForm. " DisplayOptions

Hi,

Iam using fn . module POPUP_WITH_TABLE_DISPLAY for my requirement where Iam displaying my internal table data on the screen.

FUNCTION popup_with_table_display.

*"----


""Local interface:

*" IMPORTING

*" VALUE(ENDPOS_COL) TYPE INT4

*" VALUE(ENDPOS_ROW) TYPE INT4

*" VALUE(STARTPOS_COL) TYPE INT4

*" VALUE(STARTPOS_ROW) TYPE INT4

*" VALUE(TITLETEXT) TYPE CHAR80

*" EXPORTING

*" VALUE(CHOISE) LIKE SY-TABIX

*" TABLES

*" VALUETAB

*" EXCEPTIONS

*" BREAK_OFF

*"----


I have 2 issues.

1. 3 fields are displayed on the screen. Even, if I select 1st row on the screen, Iam getting CHOISE vaues as '3' and so on.

Why its happening? What may b the problem?

2. CALL FUNCTION 'POPUP_WITH_TABLE DISPLAY'

EXPORTING

ENDPOS_COL = 40

ENDPOS_ROW = 12

STARTPOS_COL = 20

STARTPOS_ROW = 5

TITLETEXT = 'Demo'

IMPORTING

CHOISE = choice

TABLES

VALUETAB = it_Sd

EXCEPTIONS

BREAK_OFF = 1

OTHERS = 2.

Now, 5 records are displaying on the screen with above end positions and start positions.

If I have 50 records, does all of them get displayed on the screen.

If 'NO', what can I do to see all the data in the internal table on screen irrespective of no. of records?

Thanks,

Shivaa........

1 REPLY 1
Read only

Former Member
0 Likes
1,416

Hello Shiva,

This FM works like a charm for me, try out the following code


Data : Begin Of tOptions Occurs 50 ,
          VTEXT(10),
       End Of tOptions.

Data : cChoice Like SY-TABIX.
   Clear   tOptions.
   Refresh tOptions.
   Do 50 Times.
      tOptions-VTEXT = sy-Index.
      Append tOptions.
   EndDo.

Perform DisplayOptions.
*
Form DisplayOptions.
   Clear : cChoice.
   Call Function 'POPUP_WITH_TABLE_DISPLAY'
     Exporting
       EndPOS_Col   = 130
       EndPOS_Row   = 15
       StartPos_Col = 50
       StartPos_Row = 11
       TitleText    = 'Select processing option...'
    Importing
      Choise        = cChoice
    Tables
      ValueTab      = tOptions
   Exceptions
     Break_Off      = 1
     Others         = 2.
   Read Table tOptions
        Index cChoice.
   Write cChoice.
EndForm. " DisplayOptions