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

SAP ABAP - HOW TO WRITE HARD CODE to activate some code for 2months

Former Member
0 Likes
1,011

HOW TO WRITE HARD CODE to activate some code for 2months

from date: 2/01/2014

to date: 2/03/2014

Here I need to activate some code for this period can any one please suggest me

Thanks in advance

HOW TO WRITE HARD CODE to activate some code for 2months

from date: 2/01/2014

to date: 2/03/2014

Here I need to activate some code for this period can any one please suggest me

Thanks in advance

3 REPLIES 3
Read only

archanapawar
Contributor
0 Likes
727

Hi Kavi,

Please describe your issue clearly. What needs to be hardcoded? Hard-coing is not a good practice. Let me know what you are trying to achieve clearly.

Read only

rajkumarnarasimman
Active Contributor
0 Likes
727

Hi Kavi,

Hardcoding is not better idea. If you required to do it means, instead of hardcoding, better use TVARV Table. .

Maintain the value in TVARV table as shown above. And in program read the value from table and use the same. If we do like that, we can prevent hardcoding process.

Regards

Rajkumar Narasimman

Read only

jayanthi_jayaraman
Active Contributor
0 Likes
727

HI,

Use any table which you will use for maintaining constants or in selection screen provide the option for entering the date in which you want to have particular code working.

Then in your code, put the condition,

If sy-datum falls in date range in selection screen.

coding here..

endif.