Hi everyone,
In my module i pretend search a value corresponding to a variable a.
But when i run the code variable h are incorrect, because apeear error 2042 and the suppose is appear a number.
My code is:
Sub Macro3()
Dim j As Variant
Dim a As Variant
Dim h As Variant 'variavel de teste
Set Model = Workbooks("AtrasosTotal.xlsm").Worksheets("Model")
lastRowZModel = Model.Cells(Model.Rows.Count, "A").End(xlUp).Row
a = 1600104092
Sheets("Model").Select
Set b = Range("A2:O" & lastRowZModel)
h = Application.VLookup(a, b, 12, False)
End Sub
How can I resolve this problem