File Status 9/161 when opening a file with CALL 'EXTFH'

[Migrated content. Thread originally posted on 04 February 2011]

In order to bind ISAM data to ADO controls, we have set up a trial project in Visual Cobol R3 that uses the Microfocus File Handler (we also use this in our NetExpress 4.0 projects).
Opening a file with call 'EXTFH' returns a file status 9/161 (something wrong with the file header?).
When running the same code in NetExpress, this returns a file status zero (which is ok).
Does someone know what might be the solution to this problem?
Parents
  • I had an incident today with a different customer who was also getting the status 9/161 when trying to open a file by calling EXTFH directly.

    What I found in this case was that they needed to add an additional line of code to the initialization of the FCD areas.

    move fcd--version-number to fcd-version

    In FCD2 copybook fcd--version-number = 0
    In FCD3 copybook fcd--version-number = 1

    If this line is missing in Net Express 4.0 then it didn't matter as long as the FCD area was initialized to low-values because fcd--version-number in the FCD2 copybook is = 0.

    If this line is missing in Visual COBOL or when using the P64 directive in Net Express then the file handler believes that it is using an FCD2 layout instead of FCD3, hence the 9/161 error.

    Perhaps this is your issue also?
Reply
  • I had an incident today with a different customer who was also getting the status 9/161 when trying to open a file by calling EXTFH directly.

    What I found in this case was that they needed to add an additional line of code to the initialization of the FCD areas.

    move fcd--version-number to fcd-version

    In FCD2 copybook fcd--version-number = 0
    In FCD3 copybook fcd--version-number = 1

    If this line is missing in Net Express 4.0 then it didn't matter as long as the FCD area was initialized to low-values because fcd--version-number in the FCD2 copybook is = 0.

    If this line is missing in Visual COBOL or when using the P64 directive in Net Express then the file handler believes that it is using an FCD2 layout instead of FCD3, hence the 9/161 error.

    Perhaps this is your issue also?
Children
No Data