title: Timer.Enabled = False does not stop Timer tick
body: <p>I have here my code to send SMS:</p>
  <pre><code>Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
      count = DataTable1DataGridView.Rows.Count
      For i As Integer = count To 1 Step -1
          Try
              If SerialPort1.IsOpen Then
                  'dataGridView1()
                  ' TextBox1.Text = Me.dataGridView1.Rows(0).Cells(2).Value.ToString()
                  With SerialPort1
                      .Write(&quot;AT&quot; &amp; vbCrLf)
                      .Write(&quot;AT+CMGF=1&quot; &amp; vbCrLf)
                      .Write(&quot;AT+CMGS=&quot; &amp; Chr(34) &amp; DataTable1DataGridView.Rows(i - 1).Cells(2).Value.ToString &amp; Chr(34) &amp; vbCrLf)
                      .Write(ES_MSG.Rows(0).Cells(0).Value.ToString &amp; Chr(26))
                  End With
              Else
                  MsgBox(&quot;Error on the port selected&quot;)
              End If
          Catch ex As Exception
              MsgBox(ex.Message)
          End Try
          If (i = count) Then
              Exit For
              Timer1.Enabled = False
              Timer1.Stop()
          End If
          MsgBox(&quot;Message Sent!&quot;)
      Next
      Timer1.Enabled = False
      Timer1.Stop()
  End Sub
  </code></pre>
  <p>I have enabled timer through a button_click. My problem is timer doesn't seem to stop no matter where I put the Timer.Stop() and Timer.Enabled = False. The worse is when there are errors or when the message is sent, the pop-up seems to appear infinitely even if the count from my datagrid is just small. Can anyone share ideas? I really need it. Thanks.</p>