Reporting Services / Dundas图表的单元格格式字符串

时间:2021-08-19 08:22:08

Reporting services use format strings to auto format cell data. For example "c2" formats a cell to be displayed as currency with a decimal precision of 2.

报告服务使用格式字符串自动格式化单元格数据。例如,“c2”格式化要显示为货币的单元格,小数精度为2。

Does anyone know where I'd find a comprehensive list off all the different formats available?

有谁知道我在哪里可以找到所有不同格式的综合列表?

1 个解决方案

#1


Reporting Services uses the .Net formatting strings. So you can look them up on MSDN. Here is a link to the standard codes and here is the reference for creating custom codes.

Reporting Services使用.Net格式字符串。所以你可以在MSDN上查找它们。以下是标准代码的链接,以下是创建自定义代码的参考。

A standard code is one like "C2" you gave as an example and the advantage is that it's "aware" of you're Regional Settings. So C2 in the US is formatted differently to C2 in Japan.

标准代码就像您给出的“C2”一样,其优点是它“了解”您的区域设置。因此,美国的C2格式与日本的C2格式不同。

A custom code allows you to roll your own. e.g. "#,##0.0" will format a number to one decimal place with thousands seperator and will have a leading 0 if the value is between 1 and -1. With a custom string you can also have seperate formatting if it's positive, negative or 0.

自定义代码允许您自己滚动。例如“#,## 0.0”将使用数千个分隔符将数字格式化为一个小数位,如果值介于1和-1之间,则将前导0。使用自定义字符串,如果它是正数,负数或0,您也可以使用单独的格式。

#1


Reporting Services uses the .Net formatting strings. So you can look them up on MSDN. Here is a link to the standard codes and here is the reference for creating custom codes.

Reporting Services使用.Net格式字符串。所以你可以在MSDN上查找它们。以下是标准代码的链接,以下是创建自定义代码的参考。

A standard code is one like "C2" you gave as an example and the advantage is that it's "aware" of you're Regional Settings. So C2 in the US is formatted differently to C2 in Japan.

标准代码就像您给出的“C2”一样,其优点是它“了解”您的区域设置。因此,美国的C2格式与日本的C2格式不同。

A custom code allows you to roll your own. e.g. "#,##0.0" will format a number to one decimal place with thousands seperator and will have a leading 0 if the value is between 1 and -1. With a custom string you can also have seperate formatting if it's positive, negative or 0.

自定义代码允许您自己滚动。例如“#,## 0.0”将使用数千个分隔符将数字格式化为一个小数位,如果值介于1和-1之间,则将前导0。使用自定义字符串,如果它是正数,负数或0,您也可以使用单独的格式。