I know this is going to be very specific, and I'll be lucky if anyone who has experience on this topic sees this, but I've run out of patience trying to search for answers so I thought I might see if anyone in the community knows.
I'm trying to build a PeopleCode generated report that reads data from a staging table and writes it to an Excel spreadsheet. To do this, I'm using an Oracle library called "PSSpreadsheet". Other than the PeopleBooks documentation, there is little to no information about the library online. My problems lie with these two functions: SetCellHeaderStyle() and SetColumnWidth().
First of all, SetCellHeaderStyle() takes the following parameters:
- rownum/colnum
- redvalue
- bluevalue
- greenvalue
- boldweight
- color
- fontheight
- fontname
I only have issues with the red/blue/green values. No matter combination of numbers I set as parameters (0 to 256), the cells I apply the function to are gray and have a double lined border. This means if I want to use this function and change any formatting it provides, I have to deal with this bizarre color/border style.
The next function SetColumnWidth() only takes two parameters:
- colnum
- width
Pretty straightforward wouldn't you agree? When I run my code (where &SS is my spreadsheet object):
&SS.SetColumnWidth(1, 25);
&SS.SetColumnWidth(2, 25);
&SS.SetColumnWidth(3, 1);
&SS.SetColumnWidth(15, 1);
&SS.SetColumnWidth(27, 1);
Which is meant to set column A and B to width 25; and column C, O and AA to width 1, it just collapses the columns. As in they all have a width of 0 when I create the report.
Can anyone help to understand how to apply these formatting functions to my code? I'm sort of at my wit's end with this stuff and I'm not sure if the library sucks, or if I just don't understand it.
Thanks in advance.