Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[C#] DataGridView mit DataSet refreshen

Empfohlene Antworten

Veröffentlicht

Moin,

da bin ich wieder :D

Habe den halben Tag google durchgewälzt, gefühlte 100.000 Code-Schnipsel getestet... Aber irgendwie nichts hilft.

Über eine zweite Form füge ich eine neue Row in mein DataSet, welches ich dann erneut an das DataGridView anbinde und refreshe.

Leider zeigt er mir den neuen Eintrag aber nicht an - kann mir jemand sagen, woran das liegt?


        public void getValuesFromAddClientAndSetToTable(DTOClientInfo dto)

        {

            DataRow newDataRow = dataSet.Tables[0].NewRow(); // Table[0] of ds is the data I want to display

            newDataRow["Titel"] = dto.Titel;

            newDataRow["Anrede"] = dto.Anrede;

            newDataRow["Firmenname"] = dto.Firmenname;

            newDataRow["Vorname"] = dto.Vorname;

            newDataRow["Nachname"] = dto.Nachname;

            newDataRow["Zusatz"] = dto.Zusatz;

            newDataRow["Strasse"] = dto.Strasse;

            newDataRow["Nr."] = dto.Hausnummer;

            newDataRow["Ort"] = dto.Ort;

            newDataRow["PLZ"] = dto.PLZ;

            newDataRow["E-Mail"] = dto.Email;

            newDataRow["Bemerkungen"] = dto.Bemerkungen;


            dataSet.Tables[0].Rows.Add(newDataRow);


            dataGridView1.DataSource = dataSet.Tables[0].DefaultView;


            dataGridView1.Refresh();


        }

Danke und Gruß

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.