5
Answers

C# Report viewer doesn't refresh on data changes (SOLVED)

Ask a question
juanaGris

juanaGris

12y
19.4k
1
Good evening everyone,

I've made a ReportViewer using a dataset, with the wizards. My problem is that everytime a change is made in the database, the changes don't reflect in my ReportViewer graphic at runtime-unless I close my form and open again, but of course that it's not the best. I'm using MySQL and had no problems creating the dataset. 

I've tried:
        private void button1_Click(object sender, EventArgs e)
        {
            reportViewer1.Clear();
            reportViewer1.RefreshReport();
        }

The graphic blinks at it is refreshing, but the data displayed is the old one. Please help me, I'm very close to a deadline and nothing I've found on Google has worked... I'm using Visual Studio 2010.

Regards

Answers (5)