title: JS searching function does not search data on every page
body: <p>I am trying to Search records from gridview with pagination, matching with the values entered into textbox, and its working quite fine. Issue is that it only show the records which are at first page , but not search the records from the next pages.</p>
  
  <p>here is my JS. code</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
      function Search_Gridview(strKey, strGV) {
          var strGV = '&lt;%= GridView1.ClientID %&gt;';
          var strData = strKey.value.toLowerCase().split(" ");
          var tblData = document.getElementById(strGV);
          var rowData;
  
          for (var i = 1; i &lt; tblData.rows.length; i++) {
              rowData = tblData.rows[i].innerHTML;
              var styleDisplay = 'none';
              for (var j = 0; j &lt; strData.length; j++) {
                  if (rowData.toLowerCase().indexOf(strData[j]) &gt;= 0)
                      styleDisplay = '';
                  else {
                      styleDisplay = 'none';
                      break;
                  }
              }
              tblData.rows[i].style.display = styleDisplay;
         }
     }
  &lt;/script&gt;
  </code></pre>
  
  <p>and my gridview</p>
  
  <pre><code>&lt;asp:TextBox ID="txtSearch" runat="server" Font-Size="20px" onkeyup="Search_Gridview(this, 'gvTest')"&gt;&lt;/asp:TextBox&gt;&lt;br /&gt;
  &lt;div class="rounded-corners"&gt;
    &lt;div style="width: 100%; overflow: auto;"&gt;
      &lt;asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="False" AutoGenerateColumns="False" DataKeyNames="POS ID" GridLines="Horizontal" BorderColor="#ECF0F1" BorderRadius="15px" AlternatingRowStyle-BackColor="#F2F3F4" RowStyle-Wrap="false"
        HeaderStyle-Wrap="false" RowStyle-BorderColor="#e8e8ec" CssClass="gridviewdesign " RowStyle-CssClass="GV" OnSelectedIndexChanged="GridView1_OnSelectedIndexChanged" OnRowCommand="GridView1_OnRowCommand" OnRowDeleting="GridView1_OnRowDeleting" OnPageIndexChanging="GridView1_OnPageIndexChanging"
        EmptyDataText="No point of sales to display"&gt;
        &lt;Columns&gt;
          &lt;asp:CommandField HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" ButtonType="Image" HeaderText="Actions" DeleteImageUrl="~/assets/global/img/deletee.png" SelectImageUrl="~/assets/global/img/edit.png" ShowDeleteButton="True" ShowHeader="True"
            ShowSelectButton="True" /&gt;
          &lt;asp:BoundField DataField="POS ID" HtmlEncode="False" HeaderText="POS ID" ReadOnly="True" SortExpression="POS ID" HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" /&gt;
          &lt;asp:BoundField DataField="Name" HtmlEncode="False" HeaderText="Name" SortExpression="Name" HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" /&gt;
          &lt;asp:BoundField DataField="Country" HtmlEncode="False" HeaderText="Country" SortExpression="Country" HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" /&gt;
          &lt;asp:BoundField DataField="City" HtmlEncode="False" HeaderText="City" SortExpression="City" HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" /&gt;
          &lt;asp:BoundField DataField="Address" HtmlEncode="False" HeaderText="Address" SortExpression="Address" HeaderStyle-CssClass="gridView1" ItemStyle-CssClass="gridviewBody" /&gt;
  
        &lt;/Columns&gt;
        &lt;PagerStyle CssClass="pagination-ys" /&gt;
      &lt;/asp:GridView&gt;
    &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>