title: Blinking selectedindex on listview
body: <p>I'm trying to refresh a listview using a <code>timer</code>.
  the code works fine, however the problem is that the <code>selectedindex</code> is blinking maybe because the data/ui reloads itself every 1sec.</p>
  
  <p>what I want, when the user navigate I want the <code>selectedindex</code> to retain without blinking the currentlist highlight.</p>
  
  <p>the <code>145</code> transaction number there is highlighted... it blinks the highlight every 1 sec due to timer. how can I prevent it from blinking? thanks in advance...</p>
  
  <p><a href="https://i.stack.imgur.com/Kzj0W.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Kzj0W.png" alt="enter image description here"></a></p>
  
  <p>here's my code:</p>
  
  <pre><code>    public OrderCashieringView()
      {
          Timer time = new Timer();
          time.Interval = (10 * 100);
          time.Tick += time_Tick;
          time.Start();
      }
  
  
      void time_Tick(object sender, EventArgs e)
      {
          if (lstOrders.IsDisposed == false)
          {
              int CurrentRow = lstOrders.SelectedIndex;
              LoadDataCore();
              lstOrders.SelectedIndex = CurrentRow;
          }
      }
  
  
      void LoadDataCore()
      {
              if (txtSearchOrderNumber.Text == String.Empty)
              {
                  _model = svc.GetForPayment();
              }
              else
              {
                  _model = svc.GetForPayment().Where(a =&gt; a.TransactionNumber.Contains(txtSearchOrderNumber.Text)).ToArray();
              }
  
              if (lstOrders.InvokeRequired)
              {
                  this.Invoke(new MethodInvoker(() =&gt;
                  {
                      lstOrders.DataSource = _model.ToArray();
                  }));
              }
              else
              {
                  lstOrders.DataSource = _model.ToArray();
              }
  
      }
  </code></pre>