bengbengbalabalabeng opened a new issue, #676:
URL: https://github.com/apache/fesod/issues/676

   ### Search before asking
   
   - [x] I searched in the [issues](https://github.com/apache/fesod/issues) and 
found nothing similar.
   
   
   ### Fesod version
   
   1.3.0
   
   ### JDK version
   
   JDK 17
   
   ### Operating system
   
   _No response_
   
   ### Steps To Reproduce
   
   ```java
   File file = new File("/path/simple.csv");
   
   List<List<String>> head = List.of(
         List.of("No"),
         List.of("Name"),
         List.of("Age")
   );
   
   List<List<String>> data = List.of(
         List.of("1", "Jackson", "20"),
         List.of("2", "Tom", "21"),
         List.of("3", "Sophia", "20")
   );
   
   FastExcel.write(file)
         .head(head)
         .registerWriteHandler(new CustomCsvWorkbookWriteHandler())
         .csv()
         .doWrite(data);
   ```
   
   ```java
   @Slf4j
   public class CustomCsvWorkbookWriteHandler implements WorkbookWriteHandler {
         @Override
         public void afterWorkbookDispose(WorkbookWriteHandlerContext context) {
            WriteWorkbookHolder workbook = context.getWriteWorkbookHolder();
   
            Sheet sheet = workbook.getWorkbook().getSheetAt(0);
   
            Row row = sheet.getRow(0);
            // expected to return the "Age" column CsvCell object here
            Cell cell = row.getCell(2);
   
            log.info("Header name is: {}", cell.getStringCellValue());
         }
      }
   }
   
   
   ### Current Behavior
   
   cell.getStringCellValue() equal to "Name".
   
   ### Expected Behavior
   
   cell.getStringCellValue() should be equal to "Age".
   
   ### Anything else?
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [x] I'm willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to