cancel
Showing results for 
Search instead for 
Did you mean: 

how tp debug script in background?

Former Member
0 Kudos

Hi All,

How to debug a script, which runs in background. After switching on the debugger from SE71, it doesnt work in background ( ihave checked this one)

Do we have any other method?

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

at first, ask if there´s a possibility to process your output type not in background, like ME9K or like this.

if not, goto SE71 and activate debugger.

next, type /h in your ok-code box and hit enter.

now use the menu, Debugging->update task debugging.

this switches on background debugging. now your script debugger should stop even in update task.

Former Member
0 Kudos

Hi,

U try to write an infinite loop in ur driver program, before the OPEN_FORM, then run the job.

now go to SM37, ur job will be in active mode, select the job, click on JOB menu-->Capture :active job or press cntrlshiftF7. it will take u in debugg mode where u write the infinite loop.

eg:

data : lv1 TYPE i.

DO.

if lv1 EQ 1.

EXIT.

ENDIF.

ENDDO.

CALL FUNCTION 'OPEN_FORM'.

In runtime, change the value of variable LV1 to '1'.

Rgds,

Pavan

former_member205763
Active Contributor
0 Kudos

for debugging background jobs,

Use SM37 to get list of jobs, type 'JDBG' in the command line put the cursor on the job and press ENTER

Former Member
0 Kudos

Hi Mannu,

Activate the debugger through transaction SE71 and also apply breakpoint in print program to the FM 'OPEN_FORM' when the sap script is called.

This will surely help you to debugg th SS in backgroud.

Regards,

Prashant Gaikwad