Skip to Content
0
Former Member
Apr 25, 2007 at 01:10 PM

selection screen help

24 Views

Hallow I wont to do selection screen on several courses

But if I choose course num ex. 1 and 2 and 3

I get in c_ourse table (low) 3 and 2 and 3 <b>without course 1</b> why?

here is my code

SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-t02.

SELECT-OPTIONS c_course FOR z_course_table-objid

OBLIGATORY NO INTERVALS NO-EXTENSION.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR c_course-low. " value for f4

*======================================================

REFRESH: c_course.

CLEAR: c_course.

PERFORM get_objid USING 'D'

CHANGING c_course-low.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR c_course-high.

*======================================================

REFRESH: c_course.

CLEAR: c_course.

PERFORM get_objid USING 'D'

CHANGING c_course-high.

FORM get_objid

USING p_otype

CHANGING p_c_course.

*p_so_orgeh_low

CALL FUNCTION 'RH_OBJID_REQUEST'

EXPORTING

plvar = '01'

otype = p_otype

seark = '*'

seark_begda = pn-begda

  • so_date-low

seark_endda = pn-endda

  • so_date-high

set_mode = 'X' " for select one course

  • DYNPRO_REPID = ' '

  • DYNPRO_DYNNR = ' '

  • DYNPRO_PLVARFIELD = ' '

  • DYNPRO_OTYPEFIELD = ' '

  • DYNPRO_SEARKFIELD = ' '

  • CALLBACK_PROG = ' '

  • CALLBACK_FORM = ' '

  • RESTRICT_FB = ' '

  • RESTRICT_DATA = ' '

  • WITHOUT_RSIGN =

  • WITHOUT_RELAT =

  • WITHOUT_SCLAS =

  • ORGBEG = SY-DATUM

  • ORGEND = SY-DATUM

  • WIN_TITLE =

  • APP_DATA =

IMPORTING

sel_plvar = wa_plvar

sel_otype = wa_otype

sel_object = wa_objid

TABLES

  • OTYPE_TABLE =

  • CONDITION =

  • BASE_OBJECTS =

  • MARKED_OBJECTS =

sel_objects = itab_object

  • SEL_HROBJECT_TAB =

  • SEL_HRSOBID_TAB =

EXCEPTIONS

cancelled = 1

wrong_condition = 2

nothing_found = 3

internal_error = 4

illegal_mode = 5

OTHERS = 6

.

IF sy-subrc <> 0.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

IF wa_otype = 'D' .

  • OR wa_otype = 'DC' OR wa_otype = 'L'.

REFRESH: c_course.

CLEAR: c_course.

LOOP AT itab_object.

CLEAR c_course.

c_course-low = itab_object-objid.

c_course-option = 'EQ'.

c_course-sign = 'I'.

APPEND c_course.

ENDLOOP.

CLEAR: itab_object.

REFRESH: itab_object.

ENDIF.

ENDFORM. " get_objid