three line program...
Find returns a Range object, so you need to use the Set
statement. You might try declaring it first also. its
usually better to do early binding.
Dim Result as Range
Sheets("Sheet1").Select
Range("A1").Select
Set Result = Cells.Find("12345")
-----Original Message-----
Hi all...
why would this fail?
Sheets("Sheet1").Select
Range("A1").Select
Result = Cells.Find("12345") '<-error
Runtime Error 91: Object variable or With block variable
not set.
Many thanks!
Mike
.
|