在Crystal Reports登录时出现问题? [英] Problem on Crystal Reports Log in?

查看:130
本文介绍了在Crystal Reports登录时出现问题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好朋友,

我尝试SAP Crystal Reports.在安装sap exe之前.我得到一个错误.我也张贴在这里.但是一个人删除了.没关系.

现在我达到了75%.

我正在为我的程序使用Model1.edmx.但是Crystal报表需要一个dataset.xsd.所以我也补充了

Hello Friends,

I try sap Crystal Reports. before i install the sap exe. i get one error. i post that here also. But one guy delete that. its ok.

Now i reach 75%.

I am using Model1.edmx for my program. But crystal reports want one dataset.xsd. so i added that also.

CrystalReport2 cr2 = new CrystalReport2();
CrystalReportViewer rpt = new CrystalReportViewer();
WindowsFormsHost host = new WindowsFormsHost();
rpt.ReportSource = cr2;
host.Child = rpt;
reportGrid.Children.Add(host);



在查看Crystal Report时,正在出现登录"窗口.我的服务器名称是192.168.1.100,但显示mcs_kioskDataSet.

我的连接字符串是



In viewing Crystal Report, Login window is appering. my server name is 192.168.1.100 but it show mcs_kioskDataSet.

my connection string is

<add key="Connection String" value="SERVER=192.168.1.100;DATABASE=mcs_kiosk;UID=root;PASSWORD=;" />



如果我手动输入.它给了登录失败的窗口.

我如何在水晶报表的数据集中实现此连接字符串.

请帮助我.

和代码项目人员.请不要删除此问题.这是另一个问题.首先,您要阅读完整并采取行动.不要以为你只有聪明.

更新-

我的代码-



if i put manualy,. it gave login failed window.

how can i implement this connection string in dataset for crystal report.

pls help me.

and code project guys,. pls dont delete this question. this is different question. first you read fully, and take action. dont think you only intelligent.

Update -

My Code -

private void Window_Loaded(object sender, RoutedEventArgs e)
{            
            CrystalReport2 cr2 = new CrystalReport2();
                CrystalReportViewer rpt = new CrystalReportViewer();

                ConnectionInfo ci = new ConnectionInfo();                
                ci.ServerName = "192.168.1.100";
                ci.DatabaseName = "mcs_kiosk";
                ci.UserID = "root";
                ci.Password = "";
                SetDBLogonForReport(ci, cr2);

                WindowsFormsHost host = new WindowsFormsHost();
                rpt.ReportSource = cr2;
                host.Child = rpt;
                reportGrid.Children.Add(host);
}





private void SetDBLogonForReport(ConnectionInfo connectionInfo, ReportDocument reportDocument)
       {
           Tables tables = reportDocument.Database.Tables;
           foreach (CrystalDecisions.CrystalReports.Engine.Table table in tables)
           {
               TableLogOnInfo tableLogonInfo = table.LogOnInfo;
               tableLogonInfo.ConnectionInfo = connectionInfo;
               table.ApplyLogOnInfo(tableLogonInfo);
           }
       }



在运行时间.水晶报表加载,..一段时间后,一个数据库登录窗口打开..

它询问服务器名称,数据库名称,loginId,密码.我对此给予正确的回答.但登录失败,请重试抛出信息.

我正在使用vs 2010,我的sql.



In Running time,. the crystal report loading,.. after some time one Database login window is open,.

it ask servername, database name, loginId, Password. I give correct anwser to that. but login Faild please try again information was thrown.

i am using vs 2010, my sql.

推荐答案

在这里,你去了

C#Crystal Reports动态登录参数 [了解Crystal Reports中的登录失败错误 [ ^ ]

使用具有.NET的Crystal Reports对数据库登录错误进行故障排除 [ ^ ]

Here you go

C# Crystal Reports Dynamic Logon parameters[^]

Free attachment

Understanding the Login Failed Error in Crystal Reports[^]

Troubleshooting Database Login Errors using Crystal Reports with .NET[^]

Sagotharan Jagadeeswaran写道:
Sagotharan Jagadeeswaran wrote:

和代码项目专家.请不要删除此问题.这是另一个问题.首先,您要阅读完整并采取行动.不要以为你只聪明.


顺便说一句,Code项目人员呢? :-)


BTW now what about Code project guys? :-)


这篇关于在Crystal Reports登录时出现问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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