tlacitko, kterym potvrzujete zadana data ve formulari by mohlo mit takovyto kod: Private Sub cmbOK_Click()
Dim Duplicita As String
On Error Resume Next
Duplicita = List1.Range("B:B").Find(CVar(UserForm1.txtRC.Text), , , xlWhole).Address
If Err.Number = 91 Then
MsgBox "bez duplicity"
'...dalsi kod
Unload Me
Exit Sub
End If
MsgBox "Tato hodnota jiz v seznamu existuje na adrese: " & Duplicita
Unload Me
End Subcitovat
Dim Duplicita As String
On Error Resume Next
Duplicita = List1.Range("B:B").Find(CVar(UserForm1.txtRC.Text), , , xlWhole).Address
If Err.Number = 91 Then
MsgBox "bez duplicity"
'...dalsi kod
Unload Me
Exit Sub
End If
MsgBox "Tato hodnota jiz v seznamu existuje na adrese: " & Duplicita
Unload Me
End Subcitovat