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

Option List

Former Member
0 Likes
873

Dear Experts,

I hv following scenario.

I hv taken a PARAMETER : p_swerk type iloa-swerk.

everything is going fine except when when I click on list option, it display a dialog box with options.

this dialog box should display only two option ( as we ha defined two Maintenance Plant 1004, 3000), but it displays other plants also which are not in iloa table but exist in t001w.

it should plants existing in t399i table.

Thanks in advance.

Regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
786

the data element SWERK is assigned to the domain WERKS

for the domain werks in the value table table T001W is assigned.. so it will display all the plants in SWERKS.

define a custom data element with only those two plants in the value range.

this will solve your problem

even in table T399I, the data elemnt IWERK is assigned to domain T001W , which in turn has value table as T001W.

so better create a custom dataelemt

Edited by: jeevitha krishnaraj on Jul 31, 2009 8:27 AM

4 REPLIES 4
Read only

Former Member
0 Likes
787

the data element SWERK is assigned to the domain WERKS

for the domain werks in the value table table T001W is assigned.. so it will display all the plants in SWERKS.

define a custom data element with only those two plants in the value range.

this will solve your problem

even in table T399I, the data elemnt IWERK is assigned to domain T001W , which in turn has value table as T001W.

so better create a custom dataelemt

Edited by: jeevitha krishnaraj on Jul 31, 2009 8:27 AM

Read only

0 Likes
786

Thanks for ur reply

but what if I add another Maitenance Plant in future. Will the given range restrict it with value range.

Do I need to redefine the range in that case.

Regards

Read only

0 Likes
786

Hi, Try this way.


 REPORT ztest_notepad.
 DATA: it_t399i TYPE t399i OCCURS 0.
 DATA: it_return_tab TYPE ddshretval OCCURS 0,
       wa_return LIKE LINE OF it_return_tab.

 PARAMETER : p_swerk TYPE iloa-swerk.
 AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_swerk.
   IF it_t399i[] IS INITIAL.
     SELECT * FROM t399i INTO TABLE it_t399i.
   ENDIF.
   CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
     EXPORTING
       retfield    = 'IWERK'
       dynpprog    = sy-repid
       dynpnr      = sy-dynnr
       dynprofield = 'P_SWERK'
       value_org   = 'S'
     TABLES
       value_tab   = it_t399i
       return_tab  = it_return_tab.
   READ TABLE it_return_tab INTO wa_return INDEX 1.
   p_swerk = wa_return-fieldval.
Thanks Venkat.O

Read only

0 Likes
786

Dear Venkat.O

Thanks alot.

ur reply resolved my problem upto 99 %.

I need to display the Text /Name of the plant also.

Pls suggest someting for this also.

Regards

Maverick