when I start my form I'm getting the error "Type Mismatch"
Code:
Can someone help me?
Code:
Code:
Private Sub UserForm_Initialize()
Dim split_name() As String, name_person As String
Dim c As Long, contar_usuarios As Long
Workbooks(OtherBookPath).Sheets("Usuários").Activate
contar_usuarios = Cells(Rows.Count, "B").End(xlUp).Row
For c = 1 To contar_usuarios
Cells(c, 4).Select
Select Case True
Case ActiveCell = nome_usuario
name_person = ActiveCell.Offset(0, -1).Text
End Select
Next c
Workbooks(CurrentBookPath).Activate
Application.ScreenUpdating = True
split_name = Split(name_person, "")
lb_hours.Caption = Format(Now, "hh:mm")
lb_tipo_de_correc.Caption = split_name(0)
End Sub
Can someone help me?