Click here to Skip to main content
15,888,579 members
Home / Discussions / C#
   

C#

 
GeneralRe: how to fill the cells of a DataGridView directly Pin
Member 114494479-Dec-15 6:37
Member 114494479-Dec-15 6:37 
QuestionChild Window Form does not show color scheme on gridview Pin
Member 121312778-Dec-15 23:39
Member 121312778-Dec-15 23:39 
SuggestionRe: Child Window Form does not show color scheme on gridview Pin
Richard MacCutchan9-Dec-15 0:13
mveRichard MacCutchan9-Dec-15 0:13 
Questionc# for android Pin
eng_aza8-Dec-15 14:03
eng_aza8-Dec-15 14:03 
AnswerRe: c# for android Pin
Dave Kreskowiak8-Dec-15 15:27
mveDave Kreskowiak8-Dec-15 15:27 
AnswerRe: c# for android Pin
BillWoodruff8-Dec-15 16:14
professionalBillWoodruff8-Dec-15 16:14 
AnswerRe: c# for android Pin
Hari-CodeBlogger11-Dec-15 23:44
Hari-CodeBlogger11-Dec-15 23:44 
QuestionTransfer data from Dataset to Report Viewer Pin
PDTUM8-Dec-15 8:32
PDTUM8-Dec-15 8:32 
Gentleman,

And so it goes... I created the following code to accept data from my dataset on another page and propagate it in a report viewer.

C#
private void DisplayReport_Load(object sender, EventArgs e)
        {
            dataGridViewReport.DataSource = null;
            DataTable dt = ds.Tables[0];
            dataGridViewReport.DataSource = ds.Tables[0].DefaultView;

            this.reportViewer1.Reset();
            this.reportViewer1.LocalReport.ReportPath = Application.StartupPath +  @" \Report1.rdlc";
            ReportDataSource rds = new ReportDataSource("Precheck Report", dt);
            reportViewer1.LocalReport.DataSources.Clear();
            reportViewer1.LocalReport.DataSources.Add(rds);
            reportViewer1.RefreshReport();
        }


When the page loads, this page accepts the dataset value from the constructor and uses it in the code above. This has been an ordeal up until now, but I think this might be close. I think the problem might be that the report file cannot be found. Now, when I created the report file (Report1.rdlc), it appears with the other form files. What I thought I read is that this would then be located, on RUNTIME, in the /bin OR /release folder, but it does not appear to be there, nor can I copy it to that location. I cannot find where the actual path is, only the path while it is not running. So ... first, I am not sure if I have the code correct to create the report but it is no longer throwing any errors. The view display simply says that it cannot locate this file. And second, just where should I be pointing at so that this code (or any code) has the correct path to the file so the report can be created. Thank You!
AnswerRe: Transfer data from Dataset to Report Viewer Pin
Gerry Schmitz8-Dec-15 12:29
mveGerry Schmitz8-Dec-15 12:29 
GeneralRe: Transfer data from Dataset to Report Viewer Pin
PDTUM8-Dec-15 12:53
PDTUM8-Dec-15 12:53 
GeneralRe: Transfer data from Dataset to Report Viewer Pin
Gerry Schmitz8-Dec-15 13:29
mveGerry Schmitz8-Dec-15 13:29 
GeneralRe: Transfer data from Dataset to Report Viewer Pin
PDTUM8-Dec-15 14:14
PDTUM8-Dec-15 14:14 
QuestionIncomplete data after trapping Date Pin
Robert Kamarowski8-Dec-15 5:38
Robert Kamarowski8-Dec-15 5:38 
AnswerRe: Incomplete data after trapping Date Pin
Richard Deeming8-Dec-15 6:11
mveRichard Deeming8-Dec-15 6:11 
GeneralRe: Incomplete data after trapping Date Pin
Robert Kamarowski8-Dec-15 6:18
Robert Kamarowski8-Dec-15 6:18 
GeneralRe: Incomplete data after trapping Date Pin
OriginalGriff8-Dec-15 6:37
mveOriginalGriff8-Dec-15 6:37 
GeneralRe: Incomplete data after trapping Date Pin
Dave Kreskowiak8-Dec-15 7:43
mveDave Kreskowiak8-Dec-15 7:43 
GeneralRe: Incomplete data after trapping Date Pin
Richard Deeming8-Dec-15 7:51
mveRichard Deeming8-Dec-15 7:51 
GeneralRe: Incomplete data after trapping Date Pin
Robert Kamarowski8-Dec-15 8:17
Robert Kamarowski8-Dec-15 8:17 
GeneralRe: Incomplete data after trapping Date Pin
Richard Deeming8-Dec-15 8:30
mveRichard Deeming8-Dec-15 8:30 
GeneralRe: Incomplete data after trapping Date Pin
OriginalGriff8-Dec-15 8:33
mveOriginalGriff8-Dec-15 8:33 
GeneralRe: Incomplete data after trapping Date Pin
Robert Kamarowski8-Dec-15 8:43
Robert Kamarowski8-Dec-15 8:43 
GeneralRe: Incomplete data after trapping Date Pin
Robert Kamarowski8-Dec-15 10:25
Robert Kamarowski8-Dec-15 10:25 
GeneralRe: Incomplete data after trapping Date Pin
Richard Deeming9-Dec-15 2:56
mveRichard Deeming9-Dec-15 2:56 
GeneralRe: Incomplete data after trapping Date Pin
Robert Kamarowski9-Dec-15 5:07
Robert Kamarowski9-Dec-15 5:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.