Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Can someone help with the code below and see what needs to be
changed/added? I'm getting an Object variable or With block variable not set error on line - mycell_Fruit = ..Range(.cells(1,1),.cells(rows.count,1).End(xlup) ). This code was posted to me yesterday from . Thank you lastrow = Cells(Rows.Count, 3).End(xlUp).Row Dim mycell_Fruit As Range with Worksheets("sheet1") mycell_Fruit = .Range(.cells(1,1),.cells(rows.count,1).End(xlup)) End with For i = lastrow To 1 Step -1 bMatch = True for j = 6 to 10 if not isempty(cells(i,j)) then res = Application.Match(cells(i,j),mycell_Fruit,0) if iserror(res) then bMatch = False exit for end if end if next if bMatch then cells(i,"E").value = "Fruit" Next |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Evaluating mulitple criteria with COUNTIF | Excel Worksheet Functions | |||
Evaluating Equations Based on Selection !! | Excel Worksheet Functions | |||
Evaluating criteria within certain columns | Excel Programming | |||
get a total based on criteria in two columns | Excel Worksheet Functions | |||
Sum based on criteria in rows and columns | Excel Discussion (Misc queries) |