Click here to Skip to main content
13,449,326 members (42,646 online)
Rate this:
Please Sign up or sign in to vote.
See more:

my Problem is an DataGridView named "Datenansicht".

Dim sql As String
Dim data As New DataSet
Dim dataShow As New DataSet

sql = "select Eintrag_ID, Erfasser, Kategorie, Uhrzeit from Nutzereinträge"


This is how the DataGridView is filled.

Now there are Buttons who will filter the Entries in the "Datenansicht"

These re-set the DataGridView:

Dim sql As String = "select Value,ValueType from DropDownValues order by ValueType"
Dim data As New DataSet

sql = "select Erfasser, Kategorie, Uhrzeit from Nutzereinträge where Eintrag_ID Not in (Select Eintrag_ID from QMEinträge)"

Datenansicht.DataSource = Nothing
Datenansicht.DataSource = data.Tables(0)

This works, the new, filtered entries are displayed in the "Datenansicht".

But it completely breaks the events that correspond with the DataGridView "Datenansicht"

completely stops working

What I have tried:

I tried resetting the data source, clearing the whole datagridview... Nothing worked.
Posted 8-Dec-16 5:34am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web01 | 2.8.180318.3 | Last Updated 8 Dec 2016
Copyright © CodeProject, 1999-2018
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100