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: 

Regarding number of program executions

Former Member
0 Kudos

HI ,All

i have a program that will download the txt file for each time execution ,

here my requirement is for each time i need to increase the count of one field in that notepad

i.e

suppose the field will be p1

for first time execution the value will be 1

second time 2

3==3

4--4

like that i have to download that notepad

the value of p1 is included in notepad .

can any one suggest me

Regards ,

pramodh.M.

1 ACCEPTED SOLUTION

nabheetscn
Active Contributor
0 Kudos

Create a custom table with the counter. Each time store the counter in custom table for the same. Next time increment it and update database table

Nabheet

4 REPLIES 4

nabheetscn
Active Contributor
0 Kudos

Create a custom table with the counter. Each time store the counter in custom table for the same. Next time increment it and update database table

Nabheet

0 Kudos

or save the value in the table TVARVC 

regards

Fred

sivaganesh_krishnan
Contributor
0 Kudos

HI ,

Try creating a custom table and maintain counter value . So For each time you are executing the program then try increment  the table .

Try the below code for downloading .

DATA: datatab    TYPE table_of_strings,

       ld_lines   TYPE i,

       ld_file    TYPE string,

       data TYPE IBIPPARMS-PATH.

PARAMETERS: p_file(300) TYPE c ."MATCHCODE OBJECT f4_filename.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_file.

        CALL FUNCTION 'F4_FILENAME'

         EXPORTING

           PROGRAM_NAME        = SYST-CPROG

           DYNPRO_NUMBER       = SYST-DYNNR

          FIELD_NAME          = ' '

         IMPORTING

           FILE_NAME           = data              

ld_file = data.

CALL METHOD cl_gui_frontend_services=>gui_download

   EXPORTING

     filename = ld_file

   CHANGING

     data_tab = datatab                                               " pass your data here.

   EXCEPTIONS

     OTHERS   = 1.



Regards,

Sivaganesh

Former Member
0 Kudos

Thanks Nabheet/fred/Sivaganesh.

for u r valuable reply the issue is solved i exported that value into clusters pcl3 .

i have done like this EXPORT GV_COUNT   TO DATABASE PCL3(TY) ID 'xxxxx'.




import GV_COUNT   from DATABASE PCL3(TY) ID 'xxxx'.


now it is working fine


Regards ,


Pramodh.M