Application Development 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: 

Select-Options

Former Member
0 Kudos
286

Hi,

In my program I am declaring as following,

select-options: s_job for hrp1000-objid.

After I run the program I hit F4 I am getting all the Object Types, I want only the object type C which is for job.So can you guys let me know how to filter or populate my desired values.

Thanks

Vikas

1 ACCEPTED SOLUTION

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos
230

You will have to handle the F4 in your program. You can do something like this.



report zrich_0003.

tables: hrp1000.



data: begin of iplogi occurs 0,
      plvar type plogi-plvar,
      otype  type plogi-otype,
      objid  type plogi-objid,
      end of iplogi.

select-options: s_job for hrp1000-objid.


initialization.

  select * from plogi into corresponding fields of table iplogi
           where otype = 'C'.

at selection-screen on value-request for s_job-low.

  call function 'F4IF_INT_TABLE_VALUE_REQUEST'
       exporting
            retfield    = 'OBJID'
            dynprofield = 'S_JOB'
            dynpprog    = sy-cprog
            dynpnr      = sy-dynnr
            value_org   = 'S'
       tables
            value_tab   = iplogi.

REgards,

Rich HEilman

8 REPLIES 8

laxmanakumar_appana
Active Contributor
0 Kudos
230

Hi,

SELECT-OPTIONS: s_job for hrp1000-objid

MATCHCODE OBJECT Z_objid.

Z_OBJid : is user defind search help , develope this search help based on user defined database view z_view.in database view give the object type as C. then in F4 you will get the required values.

Laxman

Former Member
0 Kudos
230

u can do this

AT SELECTION-SCREEN on value request for s_job.

select objecttype from ztab where objecttype = 'C'.

former_member188685
Active Contributor
0 Kudos
230

Hi,

you need to do some coding work..

you need to call the below FM

<b>at selection-screen on value request for s_job.</b>

<b>F4IF_INT_TABLE_VALUE_REQUEST</b>

pass your own values with objet type C.

select the data for object type c, and show them as search help.

Regards

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos
231

You will have to handle the F4 in your program. You can do something like this.



report zrich_0003.

tables: hrp1000.



data: begin of iplogi occurs 0,
      plvar type plogi-plvar,
      otype  type plogi-otype,
      objid  type plogi-objid,
      end of iplogi.

select-options: s_job for hrp1000-objid.


initialization.

  select * from plogi into corresponding fields of table iplogi
           where otype = 'C'.

at selection-screen on value-request for s_job-low.

  call function 'F4IF_INT_TABLE_VALUE_REQUEST'
       exporting
            retfield    = 'OBJID'
            dynprofield = 'S_JOB'
            dynpprog    = sy-cprog
            dynpnr      = sy-dynnr
            value_org   = 'S'
       tables
            value_tab   = iplogi.

REgards,

Rich HEilman

0 Kudos
230

Rich,

I appreciate your time and effort, you read my mind.

Thanks

Vikas

0 Kudos
230

Hey, why do you need to put all that code when you can just use T513S to get the Jobs?? I feel there is no need to build a F4 logic in this case..

Regards,

Suresh Datti

0 Kudos
230

Suresh,

You are right for this scenario there is no need to build the F4 logic for now, what Richie hs done is also right I can use this logic in future.Thanks for the input.

Regards

Vikas

suresh_datti
Active Contributor
0 Kudos
230

Hi,

Replace it with

select-options: s_job for T513S-STELL.

Reagrds,

Suresh Datti