Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]() Hi: I am selecting 2 ranges formed by union. 1 is working and other is NOT. ----Code: Dim rng1, rng2, rngt As Variant dim l1,l2 as variant Set rng1 = _ Application.Union(Range("E:10:E25"), Range("G10:G25")) rng1.FormulaR1C1 = "=RC[-3]" Set rngt = Application.Union(Range("C11:c25"), rng1) Set rng2 = _ Application.Union(Range("B10:B25), Range("D10:D25")) l1 = Application.WorksheetFunction.Max(rng2) Cells.Find(What = l1).Activate------working fine l2 = Application.WorksheetFunction.Max(rngt) Cells.Find(What = l2).Activate------Error: Object or With block not set Why the 1st is working but no the 2nd one. Thanks in advance -- jesmin ------------------------------------------------------------------------ jesmin's Profile: http://www.excelforum.com/member.php...o&userid=29540 View this thread: http://www.excelforum.com/showthread...hreadid=492932 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
checking that cells have a value before the workbook will close | Excel Worksheet Functions | |||
Help with using range names in sum function | Excel Worksheet Functions | |||
function problem regarding cell range | Excel Worksheet Functions | |||
Array to named range conversion... | Excel Discussion (Misc queries) | |||
Problem with an "if" relating to a range | Excel Worksheet Functions |