Hello everyone,
I am new to this VBA Excel thingy but I am loving it. I still dont know a lot of it but I figured someone might be able to help me out with a couple macros that I have been working on.
1º So the first macro that I am trying to do is:
What the macro does now is if the code I put in the InputBox is true, it will fill up the cell with the color mentioned above. What I actually want the macro to do is if the code is true, select the entire row until last row cell being used and fill all the cell with the color mentioned (Lets say it goes until row L). It might not be as hard but since I am new it's kinda complicated for me.Sub LocalizarComp()
Código = InputBox("Qual o código a ser localizado?")
Dim myrange As Range
Set myrange = ThisWorkbook.Worksheets("Localizacao").UsedRange
For Each cell In myrange.Cells
If cell.Value = Código Then
cell.Interior.Color = 184204228
End If
Next
End Sub
Thanks for your time,
Bookmarks