Crystal Reports - “此处需要一个字符串” 公式错误
我有一个命令行实用程序,可以生成一份简单的水晶报告。 我最近使用 Visual Studio 2008 迁移器将项目从 .NET 1.1 更新到 .NET 3.5,现在收到了以前从未收到过的错误。
问题出在 work_order 公式中,如下所示:
stringVar nvl_ship_wrk_id := "0";
stringVar nvl_ship_wrk_seq := "0";
If Not IsNull({FeedBOLInput.ShipWrkId}) Then
nvl_ship_wrk_id := {FeedBOLInput.ShipWrkId};
If Not IsNull({FeedBOLInput.ShipWrkSeq}) Then
nvl_ship_wrk_seq := {FeedBOLInput.ShipWrkSeq};
nvl_ship_wrk_id & " - " & nvl_ship_wrk_seq;
错误是:
- InnerException {"A string is required here.
Error in File C:\\...\\temp_88c50533-02c6-4973-ae06-ed0ab1a603ac {0D5E96FB-038A-41C5-93A7-A9D199961377}.rpt:
Error in formula <work_order>.
'stringVar nvl_ship_wrk_id := \"0\";
'
A string is required here."} System.Exception {System.Runtime.InteropServices.COMException}
有谁知道这可能是什么? 我没有线索了。 数据集正确输入 - 并且错误似乎指向仅初始化变量的行。
I have a command line utility that generates one simple crystal report. I recently updated the project from .NET 1.1 to .NET 3.5 using the Visual Studio 2008 migrator and am now getting an error that I had never received before.
The problem is in the work_order formula which is as follows:
stringVar nvl_ship_wrk_id := "0";
stringVar nvl_ship_wrk_seq := "0";
If Not IsNull({FeedBOLInput.ShipWrkId}) Then
nvl_ship_wrk_id := {FeedBOLInput.ShipWrkId};
If Not IsNull({FeedBOLInput.ShipWrkSeq}) Then
nvl_ship_wrk_seq := {FeedBOLInput.ShipWrkSeq};
nvl_ship_wrk_id & " - " & nvl_ship_wrk_seq;
And the error is:
- InnerException {"A string is required here.
Error in File C:\\...\\temp_88c50533-02c6-4973-ae06-ed0ab1a603ac {0D5E96FB-038A-41C5-93A7-A9D199961377}.rpt:
Error in formula <work_order>.
'stringVar nvl_ship_wrk_id := \"0\";
'
A string is required here."} System.Exception {System.Runtime.InteropServices.COMException}
Does anyone have any idea what this can be? I'm out of clues. The dataset is coming in properly - and the error seems to point to a row which merely initializes a variable.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以尝试将 {FeedBOLInput.ShipWrkId} 和 {FeedBOLInput.ShipWrkSeq} 转换为字符串,以确保它作为字符串出现。
我不确定为什么你所拥有的不起作用,但看看下面的内容是否适合你。
You can try to cast the {FeedBOLInput.ShipWrkId} and {FeedBOLInput.ShipWrkSeq} to a string to make sure that it is coming across as a string.
I'm not sure why what you have wouldn't work, but see if the below works for you.