Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Read corrupted tint value from cell with gray color from standard MS Office pallete #795

Closed
lukasz-gabryel opened this issue Mar 31, 2022 · 1 comment

Comments

@lukasz-gabryel
Copy link

lukasz-gabryel commented Mar 31, 2022

This is two ways to color cell on gray color:

1 Edit format settings and set gray standard color. Technically, MS Office set color on white and set negative scientific number to tint param. Npoi can't handle this kind of number in tint so, color is just white (in memory sheet), and also after write to file this cell is white too.

2 Edit format settings, set black background, then click "more colors", go to "custom colors" and make black color lighter by slider. This operation save cell with black color and proper for NPOI tint value. After read and save sheet by NPOI cell is still gray.

I want, have this same bahavior of gray cell, with both scenarios. One chosen gray color when we edit template should be still gray after save sheet by NPOI .

I using Microsoft Excel 2022 Build 14931.20132 to edit template file.

I prepared two test sheets (cell 1A is gray but from other reasons) - please read them by NPOI and save and you will see diference.

brightening_black_cell.xlsx
brightening_black_cell_out_npoi.xlsx
darkening_white_cell.xlsx
darkening_white_cell_out_npoi.xlsx

@lukasz-gabryel
Copy link
Author

I believe this is related bug #695

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants