错误:536 文件<报告文件名>中出现错误无法连接:登录参数不正确报告文件名>
执行以下代码时,我在客户端计算机上收到上述错误
for i := 0 to crpe.Subreports.Count - 1 do
for j:=0 to crpe.Subreports[i].Tables.Count - 1 do
crpe.Subreports[i].Tables[j].Path := path;
crpe.Subreports[0]; {This line points the VCL back to the main Report}
for i := 0 to crpe.Tables.Count - 1 do
crpe.Tables[i].Path := path;
路径和表存在。当连接到没有子报表的报表时,上述代码也会失败。
我不明白为什么它给了我不正确的登录参数,因为它们只是表格。在其他机器上它工作得很好。有什么想法吗?
I am getting the above error on a client's machine when executing the following code
for i := 0 to crpe.Subreports.Count - 1 do
for j:=0 to crpe.Subreports[i].Tables.Count - 1 do
crpe.Subreports[i].Tables[j].Path := path;
crpe.Subreports[0]; {This line points the VCL back to the main Report}
for i := 0 to crpe.Tables.Count - 1 do
crpe.Tables[i].Path := path;
The path and the tables exist. The above code also fails when connecting to a report with no subreports.
I cannot see why it is given me incorrect log on parameters as they are just tables. On other machines it works just fine. Any ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试删除第四行
(crpe.Subreports[0]; {This line point the VCL back to the main Report} )
首先在您的程序似乎正在运行的机器上尝试,看看您是否真的需要该行。
如果可行,请在客户端的计算机上尝试一下,看看是否有效果。
这行代码没有任何意义。它只是引用一个对象,但不分配它或使用它。为什么它不会导致编译器错误?
-阿尔。
Try removing the fourth line
(crpe.Subreports[0]; {This line points the VCL back to the main Report} )
Try it first on a machine where your program seems to be working, to see if you really need the line.
If that works, then try it on the client's machine to see if it makes a difference.
That line of code does not make any sense. It just references an object, but does not assign it or use it. Why isn't it causing a compiler error?
-Al.