Posted 12 January 2021, 7:21 am ESTHello Support,
I'm using C1XLBook to load CSV files for processing. The Load function works as intended, bringing the files in and placing them into a book/sheets without error.
However, the files I have are unusual in that they often have a header that has fewer columns than the number of columns in the rest of the file. As such, it makes it very difficult to use the XLBook since the number of columns in an XLSheet is read-only, require me to use workarounds or reload the CSV file after altering the FileStream.
Here is a rough example:
InfoColumn1, InfoColumn2, InfoColumn3, InfoColumn4
In this case, the XLSheet column count will be set to 1 since there's only a single header in the first row. It would be much easier for me if it were set to 4, or I could set it to 4 manually
Is there any possibility to add an option to the Load function that sets the XLSheet columns to the widest number of columns in the CSV file? Failing that, could we set a number of columns to look for in CSV files and insert blanks where it fails to grab? I ask this not knowing the internal workings of the Load function, so I'm aware this may not be possible.
I'm currently developing a workaround, but it's gonna be silly, heh.