TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
tanveer ahmed
NA
2
8.3k
C# Crystal Report Error-Help required
Aug 7 2010 1:12 PM
Hi,
This is my first post, i am very new to this forum, please avoid if any mistake in writing.
I have a problem, that crystal report does not show any record when load.
I have created a Dataset in which only one table 'tblPurchaseInv' is bind.
I have created report and drag field from dataset onto report.
I have another form called frmPurchaseInv through which i want to generate invoice of last invoice which is recently saved into database. I called report on click event of SAVE button of frmPurchaseInv. The code is:
CrystalDecisions.Shared.TableLogOnInfo myLogin;
rptPurInv rpt = new rptPurInv();
frmReportViewer frm = new frmReportViewer();
foreach (CrystalDecisions.CrystalReports.Engine.Table myTable in rpt.Database.Tables)
{
myLogin = myTable.LogOnInfo;
myLogin.ConnectionInfo.ServerName = ".\\SQLExpress";
myLogin.ConnectionInfo.UserID = "";
myLogin.ConnectionInfo.Password = "";
myTable.ApplyLogOnInfo(myLogin);
}
frm.MdiParent = this.MdiParent;
frm.Show();
frm.CrViewer.SelectionFormula = "{ViewPurInv.Purchase_Inv} = " + tbpinv.Text;//
tbpinv.text is the text box having invoice number that is last saved into database
frm.CrViewer.Refresh();
frm.CrViewer.ReportSource = rpt;
When report open in Crystal Report viewer, no record shown.
Please help me!!
Reply
Answers (
0
)
problem with saving data from DataGrid to Base
OleDbException was unhandled "Incorrect syntax near the keyword 'DEFAULT'"