HI,
I wanted the code in VBA to round up the integer to the next digit.
for example: 0.1 should be 1
0.25 should be 1
1.25 should be 2 so on
--------------
lcount = Sheets("Data_sample").AutoFilter.Range.Columns(1).SpecialCells(xlCellTypeVisible).Count
lcount_1 = lcount - 1
VarRateTable = Sheets("Work Type-allocation").Range("A1:B65536")
vt = Application.WorksheetFunction.Vlookup(Cells(2, 4).Value, VarRateTable, 2, 0)
b = lcount_1 * vt
ab = Round(b)
MsgBox ab
---------------
i have used the above code but it is giving me error.
Please help.
I wanted the code in VBA to round up the integer to the next digit.
for example: 0.1 should be 1
0.25 should be 1
1.25 should be 2 so on
--------------
lcount = Sheets("Data_sample").AutoFilter.Range.Columns(1).SpecialCells(xlCellTypeVisible).Count
lcount_1 = lcount - 1
VarRateTable = Sheets("Work Type-allocation").Range("A1:B65536")
vt = Application.WorksheetFunction.Vlookup(Cells(2, 4).Value, VarRateTable, 2, 0)
b = lcount_1 * vt
ab = Round(b)
MsgBox ab
---------------
i have used the above code but it is giving me error.
Please help.