title: Replace cell content 424 error Object Required
body: <p>I am trying to replace a cell's content based on another column.</p>
  
  <p>My replace function is throwing a</p>
  
  <blockquote>
    <p><a href="https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/object-required-error-424?f1url=https%3A%2F%2Fmsdn.microsoft.com%2Fquery%2Fdev11.query%3FappId%3DDev11IDEF1%26l%3Den-US%26k%3Dk(vblr6.chm1000424)%3Bk(TargetFrameworkMoniker-Office.Version%3Dv16)%26rd%3Dtrue" rel="nofollow noreferrer">424 error Object Required</a></p>
  </blockquote>
  
  <pre><code>Public Sub OTherPN()
      CurrVal = ActiveCell.Value ' Takes the current value of the cell
  
      While CurrVal &lt;&gt; " " And NextVal &lt;&gt; " " 
          ' Checks for the condition if the next cell down is blank or
          '  does it have a command to STOP
          CurrVal = ActiveCell.Value
          MyLD = ActiveCell.Offset(0, 1).Cells
          ActiveCell.Offset(1, 0).Select
          NextVal = ActiveCell.Value
  
          While NextVal = CurrVal
              ' This is throwing an error     
              MyLD.Replace What:=ActiveCell.Offset(0, 2).Value, _
                Replacement:=ActiveCell.Offset(0, 3).Value, _
                LookAt:=xlPart, MatchCase:=False
  
              ActiveCell.Offset(1, 0).Select
              NextVal = ActiveCell.Value
          Wend
      Wend
  End Sub
  </code></pre>