Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Andrzejek on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

STRDBG not bringing up options to set breakpoints

chuckw0325

Programmer
Dec 2, 2024
11
I am running COBOL on an AS400 system. The system compiles all programs using CRTCBLPGM. I am trying to start a debug session using STRDBG. I enter STRDBG and hit F4. I enter my program name and the library. When I hit enter, it isn't taking me into the screen where I can set breakpoints and I'm not sure why. Any assistance would be greatly appreciated.

1734539209688.png
 
CRTCBLPGM creates OPM program, but on your screenshot of STRDBG the option OPM source level debug is set at *NO
 
How have you compiled the program using the CRTCBLPGM command, which options have you used?
 
The company I'm at uses WRKMBRPDM (Work with Members Using PDM) and within that menu, it uses CRTCBLPGM. I need to figure out how to make this work within the parameters they currently use. I've tried setting the Source Listing Options to *SOURCE and *SRCDBG and neither works.

1734555237200.png
 
You didn't use debugging option, press F4 on Generation options and find and add the option *SRCDBG
 
The compile command should be like this
Code:
CRTCBLPGM PGM(mylib/mypgm) SRCFILE(mysrclib/mysrcfile)
          OPTION(*SRC *SRCDBG)

If the compilation was successful then start the debugger
Code:
STRDBG (mylib/mypgm) OPMSRC(*YES)
 
That works on my local machine but I cannot get it to work when I send the compiled program to our test system. I get the message below. What else do I need to send to the test system them to get it to work there?

1734557051140.png
 
Source not available usually means that you did not compile with the debugging option.
 
What else do I need to send to the test system them to get it to work there?

The source member of the program.
To be able to debug the program, the debugger needs to have the source.
 

Part and Inventory Search

Sponsor

Back
Top