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

RE: Problem with PFKeys

$
0
0

The ADISCTRL file needs to be in the working directory for the application.

By default the working directory is the output folder of the project which is the folder containing the .EXE, .OBJ and .IDY file.
If you specify a different working directory in the properties of the run configuration then it would need to reside in the specified folder.

The alternative is to replace the default version of ADISCTRL with the modified version by copying it to the C:\program files (x86)\micro focus\visual cobol\etc folder.

It will then be found regardless of where the working directory is.

I tested this here using the following test program and it worked fine as long as the modified ADISCTRL was in the project output folder or in the etc folder.

      program-id. testad as "testad".
      environment division.
      configuration section.
      special-names.
         console is crt
         crt status is crt-status.
      data division.
      working-storage section.
      01  crt-status.
          05 crt-status-1                   pic 9.
             88  terminate-key                  value 0.
             88  function-key                   value 1.
             88  adis-key                       value 2.
             88  status-1-error                 value 9.
          05  crt-status-2                   pic 99 comp-x.
             88  esc-key                        value 0.
             88  f1-key                         value 1.
             88  enter-key                      value 1.
             88  fun-key-num-user               values 0 thru 127.
             88  fun-key-num-system             values 0 thru 26.
          05  crt-status-3                   pic 99 comp-x.
             88 raw-key-code                    values 0 thru 255.
      01 any-key     pic x.
      procedure division.

          accept any-key at 0101
             on exception
                display "code = " crt-status-2
             not on exception
                display "no key"
          end-accept
          accept any-key
          goback.
      end program testad.


Viewing all articles
Browse latest Browse all 4356

Trending Articles



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