Bordear celda en rojo y desbordear el mismo borde
Como puedo modificar este código
Dim Celda As Range, Texto As String
Sub invertido()
Application.ScreenUpdating = False
Columns("TR:TR").ClearContents
'Range("A:SZ").Interior.Color = xlNone
x = 2
For Each Celda In Range("A1:SZ42")
If Trim(Celda) <> "" Then
If Contar = Len([TH1]) Then
'Celda.Interior.Color = vbYellow
Range("TR" & x) = Celda
x = x + 1
End If
End If
Next
End Sub
'---------------------------------
Private Function Contar()
Texto = Celda
For x = 1 To Len([TH1])
i = InStr(Texto, Mid([TH1], x, 1))
If i > 0 Then
Texto = Replace(Texto, Mid([TH1], x, 1), "", 1, 1)
Contar = Contar + 1
End If
Next
End Functiony que en vez de colorear en amarillo la celda , la bordee en rojo y la desbordee en cada cambio de numero
1 respuesta
Respuesta de Elsa Matilde
2