org.apache.poi.openxml4j.exceptions.InvalidOperationException: Operation not allowed, document open in read only mode!

poi-user | Isao Kadowaki | 2 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    InvalidOperationException occurs when creating XSSFWorkbook with PackageAccess.READ

    poi-user | 2 years ago | Isao Kadowaki
    org.apache.poi.openxml4j.exceptions.InvalidOperationException: Operation not allowed, document open in read only mode!
  2. 0

    InvalidOperationException occurs when creating XSSFWorkbook with PackageAccess.READ

    poi-user | 2 years ago | Isao Kadowaki
    org.apache.poi.openxml4j.exceptions.InvalidOperationException: Operation not allowed, document open in read only mode!

    Root Cause Analysis

    1. org.apache.poi.openxml4j.exceptions.InvalidOperationException

      Operation not allowed, document open in read only mode!

      at org.apache.poi.POIXMLDocumentPart.createRelationship()
    2. POI
      POIXMLDocumentPart.createRelationship
      1. org.apache.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:370)
      2. org.apache.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:330)
      2 frames
    3. Apache POI
      XSSFWorkbook.onDocumentRead
      1. org.apache.poi.xssf.usermodel.XSSFWorkbook.onDocumentRead(XSSFWorkbook.java:274)
      1 frame
    4. POI
      POIXMLDocument.load
      1. org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:159)
      1 frame
    5. Apache POI
      XSSFWorkbook.<init>
      1. org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:186)
      1 frame