title: Find method does not work: object variable or with block variable not set
body: <p>I try to find a serial number of a row in a range but get &quot;error 91: object variable or with block variable not set&quot;.</p>
  <pre><code>a = Sheets(&quot;Sheet X&quot;).Range(&quot;A1:A1009&quot;).Find(Worksheets(i).Cells(j, 23)).Row
  </code></pre>
  <p>Interesting thing that WorksheetFunction.Match works without an error:</p>
  <pre><code>a = WorksheetFunction.Match(Worksheets(i).Cells(j, 23), Sheets(&quot;Sheet X&quot;).Range(&quot;A1:A1009&quot;), 0)
  </code></pre>
  <p>Second interesting thing is that .Find sometimes works without an error, but I cannot find any logic.</p>
  <p>Range(&quot;A1:A1009&quot;) is range of timestamps, and Worksheets(i).Cells(j, 23) is timestamp. Formatting is the same.</p>
  <p>Would be appreciated for the help. Thanks.</p>
  <p>Mikita.</p>