Closed mschnell1 closed 5 months ago
Unfortunately, there is currently no method provided for reading sheet contents or format. I've listed these features in the development plan and will release them in version 0.4. By the way, if you want to follow their development progress, you can check the dev-0.4 commit history.
Thanks for the fast answer ! This is astonishing: Write is possible, Read is not....
Moreover it's astonishing that there is no appropriate issue and Merge request. (I certainly would have found those...)
I'll try to check out v0.4 and so some tests....
Yeah !
I see very active development. Thanks !
With v0.4 I can read the cell content 👍
And Border Color 👍 👍
Hoping for Text and background colors ...
After setting fill
and fg_color
and bg_color
in formats.rs
and color.rs
to general pub
, I do get some seemingly sensible value for the foreground color (as RGB) . 👍 👍 👍
But not yet the background color (As Index: always = 64 in my example).
BTW to decently create an ADOC file, I additionally need the width of the table and the width of each column
....
Seemingly the cols
vector does not yet get filled with data from the xlsx file and hence the column widths are unknown.
After setting
fill
andfg_color
andbg_color
informats.rs
andcolor.rs
to generalpub
, I do get some seemingly sensible value for the foreground color (as RGB) . 👍 👍 👍But not yet the background color (As Index: always = 64 in my example).
Do you mean bg_color when adjusting the background color? I will try to modify thus making it easier to use. btw, not all fields can be made effective by modifying their access modifiers as I have not tested this way, after the functionality is perfected, I will make it easier by adding methods for the user to call.
BTW to decently create an ADOC file, I additionally need the width of the table and the width of each column .... Seemingly the
cols
vector does not yet get filled with data from the xlsx file and hence the column widths are unknown.
Yes, due to the specificity of the cols, I haven't provided the ability to read the width yet, and in fact, the ability to read the height is unstable, and I'm going to include refining those features in the development plan. To facilitate feedback on the progress of the development of this feature, can you open a new issue for this purpose?
I added some temporary interfaces to modify the column formatting (only column widths and background colors have been tested so far) and updated examples. Additionally, there is no specification provided in openxml for modifying the global background as far as I know, when making background changes in Excel, it just adjusts the background of the columns in a large range (this range is 1~2^14) to the desired colors.
I've released version 0.4.1, which provides the ability to read text and styles that you can find in examples/read_and_copy to see the usage.
In the current version, using format.fill
to directly read `cells, rows, columns foreground and background colors is allowed.
I'll mark this issue as completed, if you have problems with it, please don't hesitate to open an issue!
Hi Experts, Sorry for abusing an issue for asking for help, but I don't find any documemntation or examples for the supposedly trivial issue.
I'd like to read the Data content, background and foreground colors of all cells in am XLSX sheet. (The goal is to do a XLS-> ADOC converter. I don't want to write an XLSX file)
I do find
set_...()
functions for many cell propertiesm, but no "get_...()" functionality to read an existing workbook.Any help ? -Thanks