How to get column width using ExcelDataReader library?
up vote
1
down vote
favorite
I know how to get RowHeight
using(var xls2003Stream = new MemoryStream(xlsBytes))
{
using(var reader = ExcelReaderFactory.CreateReader(xls2003Stream))
{
var height = reader.RowHeight;
...
}
}
but the question is - can I get the column width using the ExcelDataReader library?
.net exceldatareader
add a comment |
up vote
1
down vote
favorite
I know how to get RowHeight
using(var xls2003Stream = new MemoryStream(xlsBytes))
{
using(var reader = ExcelReaderFactory.CreateReader(xls2003Stream))
{
var height = reader.RowHeight;
...
}
}
but the question is - can I get the column width using the ExcelDataReader library?
.net exceldatareader
1
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
xls
was abandoned 12 years ago. The format used by Excel isxlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't supportxls
except for paid subscriptions for example.
– Panagiotis Kanavos
Nov 8 at 17:19
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I know how to get RowHeight
using(var xls2003Stream = new MemoryStream(xlsBytes))
{
using(var reader = ExcelReaderFactory.CreateReader(xls2003Stream))
{
var height = reader.RowHeight;
...
}
}
but the question is - can I get the column width using the ExcelDataReader library?
.net exceldatareader
I know how to get RowHeight
using(var xls2003Stream = new MemoryStream(xlsBytes))
{
using(var reader = ExcelReaderFactory.CreateReader(xls2003Stream))
{
var height = reader.RowHeight;
...
}
}
but the question is - can I get the column width using the ExcelDataReader library?
.net exceldatareader
.net exceldatareader
edited Nov 8 at 14:32
AakashM
51.7k12123170
51.7k12123170
asked Nov 8 at 11:08
Mr-Cas
62
62
1
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
xls
was abandoned 12 years ago. The format used by Excel isxlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't supportxls
except for paid subscriptions for example.
– Panagiotis Kanavos
Nov 8 at 17:19
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54
add a comment |
1
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
xls
was abandoned 12 years ago. The format used by Excel isxlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't supportxls
except for paid subscriptions for example.
– Panagiotis Kanavos
Nov 8 at 17:19
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54
1
1
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
xls
was abandoned 12 years ago. The format used by Excel is xlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't support xls
except for paid subscriptions for example.– Panagiotis Kanavos
Nov 8 at 17:19
xls
was abandoned 12 years ago. The format used by Excel is xlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't support xls
except for paid subscriptions for example.– Panagiotis Kanavos
Nov 8 at 17:19
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54
add a comment |
2 Answers
2
active
oldest
votes
up vote
0
down vote
Based on the fact that searching the library's repo for the word width
doesn't show up anything useful, I'm going to say no it's not currently possible. But then, from the issue you opened, you knew that right? :)
add a comment |
up vote
0
down vote
accepted
Issue opened on GitHub as they just didn't implement this property.
https://github.com/ExcelDataReader/ExcelDataReader/issues/365
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
Based on the fact that searching the library's repo for the word width
doesn't show up anything useful, I'm going to say no it's not currently possible. But then, from the issue you opened, you knew that right? :)
add a comment |
up vote
0
down vote
Based on the fact that searching the library's repo for the word width
doesn't show up anything useful, I'm going to say no it's not currently possible. But then, from the issue you opened, you knew that right? :)
add a comment |
up vote
0
down vote
up vote
0
down vote
Based on the fact that searching the library's repo for the word width
doesn't show up anything useful, I'm going to say no it's not currently possible. But then, from the issue you opened, you knew that right? :)
Based on the fact that searching the library's repo for the word width
doesn't show up anything useful, I'm going to say no it's not currently possible. But then, from the issue you opened, you knew that right? :)
answered Nov 8 at 14:46
AakashM
51.7k12123170
51.7k12123170
add a comment |
add a comment |
up vote
0
down vote
accepted
Issue opened on GitHub as they just didn't implement this property.
https://github.com/ExcelDataReader/ExcelDataReader/issues/365
add a comment |
up vote
0
down vote
accepted
Issue opened on GitHub as they just didn't implement this property.
https://github.com/ExcelDataReader/ExcelDataReader/issues/365
add a comment |
up vote
0
down vote
accepted
up vote
0
down vote
accepted
Issue opened on GitHub as they just didn't implement this property.
https://github.com/ExcelDataReader/ExcelDataReader/issues/365
Issue opened on GitHub as they just didn't implement this property.
https://github.com/ExcelDataReader/ExcelDataReader/issues/365
answered Nov 8 at 17:51
Mr-Cas
62
62
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53206528%2fhow-to-get-column-width-using-exceldatareader-library%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
ExcelDataReader is meant to read Excel data, not formatting. The reader doesn't know about rows or heights, it knows how to read the next row and get column values from that row. What are you trying to do? If you care about formatting you probably need a different library, like EPPlus
– Panagiotis Kanavos
Nov 8 at 14:36
Yes i've got concept of that library, but for me it looks a bit weird that they created property RowHeight and no ColumnWidth. Anyway, it would be great if you will suggest me library which can read Excel2003 format with .NET Core support. I didn't found one.
– Mr-Cas
Nov 8 at 17:11
xls
was abandoned 12 years ago. The format used by Excel isxlsx
, a zip package containing XML files. The only reliable way to handle the obsolete format is to install Excel. That's impossible for servers or third-party applications, which is part of the reason it was abanadoned. Google Sheets doesn't supportxls
except for paid subscriptions for example.– Panagiotis Kanavos
Nov 8 at 17:19
Yes its correct that this file structure is old. But you are not right about possibility to parse it. There is open documentation about xls file structure (interoperability.blob.core.windows.net/files/MS-XLS/…). And current library i talk about in this topic can do the job, but it seems they didn't implement ColumnWidth property. AakashM right, i opened issue on GitHub.
– Mr-Cas
Nov 8 at 17:48
And only paid libraries provide good enough results, none of them as good as Excel itself. Just because the format is known doesn't mean a library can handel pivot tables, features stored as blobs, embedded objects. The contents of those fields depend on each version of Excel itself.
– Panagiotis Kanavos
Nov 8 at 17:54