Crystal Reoprt的领先零点 [英] Leading Zero in Crystal Reoprt

查看:67
本文介绍了Crystal Reoprt的领先零点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我从数据库中获取一些数据,我有一个数字字段。

我需要在该字段中显示前导零。



假设它从数据库中获取95,它在显示报告时应该显示0000095.



我试过很多方法,
FORMAT(FIELDA,000000000)但公式编辑器返回错误需要布尔值。



正确(000000000& FIELDA,9)

返回相同的错误。





请建议解决方案



Prathamesh

Hi,
I am fetching some data from Database, i have a number field.
I need to dislay Leading Zeros for that field.

Suppose it fetches 95 from database, it should Display 0000095 while showing Report.

I Tried many Ways,
FORMAT(FIELDA,"000000000") but formula editor returns error Boolean value is required.

Right("000000000"&FIELDA,9)
Same error is returned.


Please Suggest solution

Prathamesh

推荐答案

尝试所有9的格式说明符。例如。 99999999。
Try a format specifier of all 9s. E.g. "99999999".


将您的字段转换为字符串,因此公式应如下所示

Convert your field to string, so formula should be like below
Right("000000000" & CStr(FIELDA),9)



有一个选项显示领先零点 [ ^ ] in 格式化数字对话框 [ ^ ]



同时检查公式(前导零)

Crystal Reports:缺少数据 [ ^ ]


There is an option Show Leading Zero[^] in Formatting Numbers dialog box[^]

Also check this for formula(leading zero)
Crystal Reports: Missing Data[^]


用于显示字符串在格式编辑器中为5位int邮政编码CStr({Payee.Zip},00000,0)



http://pic.dhe.ibm。 com / infocenter / rsawshlp / v7r5m0 / index.jsp?topic =%2Fcom.businessobjects.integration.eclipse.designer.doc%2Fhtml%2Ftopic727.html [ ^ ]



00000是格式,0是小数位数。
For Display String in the Format Editor for a 5 digit int Zip code CStr({Payee.Zip},"00000",0)

http://pic.dhe.ibm.com/infocenter/rsawshlp/v7r5m0/index.jsp?topic=%2Fcom.businessobjects.integration.eclipse.designer.doc%2Fhtml%2Ftopic727.html[^]

"00000" is the format, 0 is the number of decimal places.


这篇关于Crystal Reoprt的领先零点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆