|
List,
I have two formats defined in my program. One sets the cell style for
currency, and the other sets the background color. They are listed
below.
Currency = HSSFWorkbook_createCellStyle(book);
DataFmt = HSSFWorkbook_createDataFormat(book);
TempStr = new_String('$#,##0.00_);[Red]($#,##0.00)');
NumFmt4 = HSSFDataFormat_getFormat(DataFmt: TempStr);
HSSFCellStyle_setDataFormat(Currency: NumFmt4);
HSSFCellStyle_setAlignment(Currency: ALIGN_RIGHT);
BG_BLUE = HSSFWorkbook_createCellStyle(book);
HSSFCellStyle_setFillForegroundColor( BG_BLUE
: HSSFColor_BLUE);
HSSFCellStyle_setFillPattern(style: SOLID_FOREGROUND);
Can anyone explain how can I combine the two so that the cell shows
$1,234.56 and is highlighted in blue?
Thanks,
Terry Anderson
Programming Manager
Grede LLC.
Switchboard 1.251.867.5481 ext 212
Direct Line 1.251.809.2312
Fax 251.867.0525
Cell 1.251.363.4975
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.