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: 

How to read screen field values from PT60 into custom time function program SAP ABAP ?

former_member396057
Participant
0 Kudos

Hi,

I am working on custom time function.I need the screen field values entered on the selection screen of standard program RPTIME00 ( Tcode : PT60 ) into my custom time function program.

How to read the values ?

Screenshot attached.time-evaluation-pt60.png

Thanks & Regards,

Shabbir

1 ACCEPTED SOLUTION

dairolozano
Contributor
0 Kudos

Hi.

You can use field symbols to read the value of any variable in another program. This example fetchs value from parameter SCHEMA in RPTIME00.

DATA: LV_SCHEMA LIKE RPTAXXXX-RSCHEMA,
      L_VAR_NAME(16) TYPE C VALUE '(RPTIME00)SCHEMA'.

FIELD-SYMBOLS: <L_FS> TYPE ANY,
               <WA>  TYPE RESBB.

ASSIGN (L_VAR_NAME) TO <L_FS>.
LV_SCHEMA = <L_FS>.

2 REPLIES 2

dairolozano
Contributor
0 Kudos

Hi.

You can use field symbols to read the value of any variable in another program. This example fetchs value from parameter SCHEMA in RPTIME00.

DATA: LV_SCHEMA LIKE RPTAXXXX-RSCHEMA,
      L_VAR_NAME(16) TYPE C VALUE '(RPTIME00)SCHEMA'.

FIELD-SYMBOLS: <L_FS> TYPE ANY,
               <WA>  TYPE RESBB.

ASSIGN (L_VAR_NAME) TO <L_FS>.
LV_SCHEMA = <L_FS>.

0 Kudos

Hi Dairo,

Thanks for the reply.

I am trying to get the end date as follows but is giving dump saying field symbol not assigned.

Ex:

DATA: LV_ENDDA LIKE RPTAXXXX-ENDDA,
      L_VAR_NAME(16)TYPECVALUE'(RPTIME00)ENDDA'.

FIELD-SYMBOLS:<L_FS>TYPEANY,

              <WA>TYPE RESBB.

ASSIGN(L_VAR_NAME)TO<L_FS>.
LV_ENDDA =<L_FS>.