I've tried so hard by myself and I've just ended up confusing myself as it's my first time using vb.
I didn't want to waste anyones time but I'm sorry I just don't know what to do..
----
How would I code this?
I want to make a progress bar that runs when a button is clicked.
However there is also a checkbox and textbox that affect the whole thing.
If the checkbox is checked and there are characters in the text box, the button works and starts the progress bar.
If the checkbox isn't checked and/or the textbox is empty, an error message comes up when the button is pressed.
----
I can almost code it but I get stuck at
Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
If String.IsNullOrEmpty(TextBox1.Text) Then
Button1.Enabled = False
Else
Button1.Enabled = True
End If
If CheckBox1.Checked = False Then
Button1_Click(MsgBox("Error. The checkbox must be ticked"))
As you probably know, that isn't right but I just don't know what to do next :(
Please help thankyou so much.