title: Count search dynamic region
body: <p>I'd like to insert a count search function into a cell and make it dynamic using VBA.</p>
  <p><a href="https://i.stack.imgur.com/EQ5IC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EQ5IC.png" alt="enter image description here" /></a></p>
  <p>In the cell G2 I want to insert the following formula: =COUNT(SEARCH(($F$2:$F$3;B2))=0 so that it returns a true or false value. As the Table in cell A1 and the column F are liable to change I need to create a code that would insert a dynamic count search function in there.</p>
  <p>This is the code I've inserted and I've tried to highlight the code from cell F2 and below but it doesn't seem to work.</p>
  <p><code>ActiveCell.Formula2R1C1 = &quot;=COUNT(SEARCH(Range.&quot;F2&quot;.Currentregion,RC[-5]))=0&quot;</code></p>
  <p>Anyone know how I can edit the code so that it looks looks up the region below F2 dynamically and creates an absolute value and also creqtes B2 a relative reference (appears to be currently RC[-5] in the code ?</p>
  <p>Thanks,</p>