正如您已閱讀標題,我一直在尋找一種方法來格式化電子表格格式的電子表格。使用下面的代碼我確實得到了我的貨幣格式,但貨幣符號顯示在數字後面。Office Open XML SDK電子表格如何在數字前面顯示貨幣符號?
// currency format
stylesheet.GetFirstChild<DocumentFormat.OpenXml.Spreadsheet.CellFormats>().InsertAt<DocumentFormat.OpenXml.Spreadsheet.CellFormat>(
new DocumentFormat.OpenXml.Spreadsheet.CellFormat()
{
NumberFormatId = 164,
ApplyNumberFormat = true
},
8);
有沒有人知道在前面顯示貨幣符號的貨幣格式NumberFormatId?
是你的答案與問題相關的$ 1.23 ? –