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 in selcet potion

Former Member
0 Likes
550

i have selection screen taht in that in box like courses when u push f4 it ope with lot of courses in tree and u can choose a course (mark the name of course u wont)my problem is that the tree is open with courses but i cant choose any of them this is my code mybe i forgat something hope u can help my .thankes

----


  • -->P_0026 text

  • <--P_SO_ORGEH_LOW text

----


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 = sy-datum

seark_endda = sy-datum

set_mode = 'X'

  • 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 = 'E '.

REFRESH: y_ergnit.

CLEAR: y_ergnit.

LOOP AT itab_object.

CLEAR y_ergnit.

y_ergnit-low = itab_object-objid.

y_ergnit-option = 'EQ'.

y_ergnit-sign = 'I'.

APPEND y_ergnit.

ENDLOOP.

CLEAR: itab_object.

REFRESH: itab_object.

ENDIF.

IF wa_otype = 'E ' .

  • 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.

p_c_course = wa_objid-objid.

ENDFORM. " get_objid

i have selection screen taht in that in box like courses when u push f4 it ope with lot of courses in tree and u can choose a course (mark the name of course u wont)my problem is that the tree is open with courses but i cant choose any of them this is my code mybe i forgat something hope u can help my .thankes

----


  • -->P_0026 text

  • <--P_SO_ORGEH_LOW text

----


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 = sy-datum

seark_endda = sy-datum

set_mode = 'X'

  • 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 = 'E '.

REFRESH: y_ergnit.

CLEAR: y_ergnit.

LOOP AT itab_object.

CLEAR y_ergnit.

y_ergnit-low = itab_object-objid.

y_ergnit-option = 'EQ'.

y_ergnit-sign = 'I'.

APPEND y_ergnit.

ENDLOOP.

CLEAR: itab_object.

REFRESH: itab_object.

ENDIF.

IF wa_otype = 'E ' .

  • 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.

p_c_course = wa_objid-objid.

ENDFORM. " get_objid

2 REPLIES 2
Read only

Former Member
0 Likes
522

Hello,

I don't know your function used but you can try to use an other one as ALV popup

Search in SE37 transaction ALVpopup*

regards

sebastien

Read only

Former Member
0 Likes
522

hi

good

check with this wheather you have pass the parameters like this or not, bcz it is giving error when i try to execute in my system

CALL FUNCTION 'RH_OBJID_REQUEST'

EXPORTING

plvar = yourplvar

otype = Yourobjecttype

dynpro_repid = self_repid

dynpro_dynnr = self_dynnr

  • dynpro_plvarfield = 'PPHDR-PLVAR'

dynpro_searkfield = 'YOURFIELDNAME'

IMPORTING

sel_object = f4_objec

EXCEPTIONS

cancelled = 1

wrong_condition = 2

nothing_found = 3

illegal_mode = 4

internal_error = 5

OTHERS = 6.

IF sy-subrc = 0.

MOVE f4_objec-realo TO yourfield.

ENDIF.

check out the paramters and do the changes accordingly.

thanks

mrutyun^