UnexpectedCastException was uhandled [solved]
I am working on a simple spammer, but I keep getting this error when making the "Set Interval"
[highlight=vb.net]
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If TextBox5.Text = ("") Then
MsgBox("Please, put a valid number value", MsgBoxStyle.Critical + MsgBoxStyle.OkOnly, "ERROR")
Else
End If
Timer1.Interval = TextBox1.Text * 1000
End Sub[/highlight]
The Timer1.Interval = ((TextBox1.Text) * (1000)) is giving the error.

[highlight=vb.net]
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If TextBox5.Text = ("") Then
MsgBox("Please, put a valid number value", MsgBoxStyle.Critical + MsgBoxStyle.OkOnly, "ERROR")
Else
End If
Timer1.Interval = TextBox1.Text * 1000
End Sub[/highlight]
The Timer1.Interval = ((TextBox1.Text) * (1000)) is giving the error.


