Quantcast
Channel: Visual COBOL - Forum - Recent Threads
Viewing all articles
Browse latest Browse all 4356

RE: Need COBSW type settings in Visual Studio for animating and testing

$
0
0

I just ran a test and these COBSW settings work for me in both native code or managed code either by setting them in the app.config file as COBSW with +B-F-N or by passing them on the command line on the debug tab using (+B-F-N)

Try the following program and tell me if it works for you? The result should be that when run the RTS error 163 caused by invalid data in the move (CHECKNUM is on) should be suppressed and the text file myfile.txt should not contain the embedded nulls before each non displayable character.

      $set checknum 
       program-id. Program1.
       input-output section.
           select test-file assign to "myfile.txt"
                           organization is line sequential
                           file status is file-status.
       data division.
       file section.
       fd test-file.
       01 test-record pic x(10).
       working-storage section.
       01 file-status pic x(2) value spaces.
       01 myspaces pic x(10) value spaces.
       01 field-1  redefines myspaces pic s9(5)v9(2).
       01 field-2 pic s9(5)v9(2).
       procedure division.

           move field-1 to field-2
           open output test-file
           display file-status
           move x"010203" to test-record
           write test-record
           close test-file
           
           goback.
           
       end program Program1.

Viewing all articles
Browse latest Browse all 4356

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>