Ich habe folgendes Problem, bei mir wird eine Combobox aus einer Tabelle gefüllt, und jetzt kommt es doch mal vor das es dort 2 gleiche Einträge gibt. Bis jetzt bin ich mit diesem Code ausgekommen:
Dim Ergebnis As Range
Dim AName As String
Dim er As Integer
AName = ComboBox1
Set Ergebnis = Sheets("Prüfbefunde").Columns(1).Find(What:=AName, LookAt:=xlWhole)
er = Ergebnis.Row
TextBox1 = Worksheets("Prüfbefunde").Cells(er, 2)
TextBox2 = Worksheets("Prüfbefunde").Cells(er, 12)
TextBox3 = Worksheets("Prüfbefunde").Cells(er, 96)
TextBox4 = Worksheets("Prüfbefunde").Cells(er, 95)
Das Problem ist halt wenn ich jetzt zum Beispiel bei Zeile 19 und 20 den gleichen Namen hat zeigt er mir bei den Textbox immer nur die Werte von Zeile 19 an obwohl ich die von Zeile 20 ausgewählt habe.
Habt ihr da eine Idee wie ich das besser mache?
Danke