excel - 1004: Application defined error when trying to examine cell contents -


I am trying to loop through the rows in my sheet, to the extent of copying the current line BF If the value is "active" in another sheet column, then cells in the row (BF) should only be added to the category and if the value is in the column (empty / nothing / zero /! # VALUE ..)

I have tried many ways around it, but I'm 1004: App / ob The Ekt get defined error first if statement

msgbox show that limit is valid, any attempt to qualify for the most Kmtm detail using cell () instead of the range of benefits.

  MsgBox (ActiveWorkbook.Worksheets ("Staging"). Category ("G" & Room (rows.count, 5) .intermination (XLEP) .ro) .vill) I = For cells (rows number, 5). End (XLEEP). For Iro = 1 phase-1 if ActiveWorkbook. Worksheets ("Staging". "(" C "& amp; i). Room (" G "&). Value =" Active " Then if not (ActiveWorkbook.Worksheets ("Staging"). Category ("C" & I)) Set againRange = Set category ("B" & amp; amp; ": F:" & amp; ) CopyRange = Union2 (copyRange, selectange) Otherwise 'Nothing Ends If Otherwise' Nothing End If Next  

Am I just missing something simple here? I have been beaten on my head.

... and For Eagle's eyes, for you, Union 2 is not typo, there is only one user-defined function, which is not to avoid joining the set range on "nothing"

Try itemprop = "text">

  1. The second row

    i = For the cell (rows.count, 5). End (XLEEP). 1 to step 1

  2. the third line

    If ActiveWorkbook.Worksheets ("Staging"). Range ("G" & amp; i) Value = "active" then


Comments