A check box is a useful way to find out what functions or tasks the user wants to show as completed or to use. A check box can be used to simply show that a task is complete or to make the program run a certain line of code.
PrivateSub btnPress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)Handles btnPress.ClickDim homework, chores, teeth As CheckBox
'A check box cannot be defined as a string, integer or char, therefore it has its own value type, and that is Checked
homework = chkBoxHomework 'This defines the homework checkbox
chores = chkBoxChores 'This defines the chores checkbox
teeth = chkBoxTeeth 'This defines the teeth checkbox'This if statment checks to see if the check box's are infact checkedIf homework.CheckedAnd chores.CheckedAnd teeth.CheckedThen
MessageBox.Show("Homework is complete", "Homework", MessageBoxButtons.OK, MessageBoxIcon.Information)
MessageBox.Show("Chores are done", "Chores", MessageBoxButtons.OK, MessageBoxIcon.Information)
MessageBox.Show("Teeth are brushed", "Teeth", MessageBoxButtons.OK, MessageBoxIcon.Information)
MessageBox.Show("All tasks completed, goodnight", "Goodnight", MessageBoxButtons.OK, MessageBoxIcon.Information)Else
MessageBox.Show("One or more tasks is not complete", "Oh no", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)EndIfEndSub
Handy Hint 2
Sort array
PrivateSub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)Handles Button1.ClickDimarray(9), array2(9)AsIntegerDim msg, msg2 AsStringDim i AsIntegerFor i =1To array.GetUpperBound(0)array(i)= i
Next
i =0For j = array2.GetUpperBound(0)To1Step-1
i +=1
array2(j)= i
Next
i =0For i =1To array.GetUpperBound(0)
msg &=array(i)& vbNewLine
Next
i =0
msg &= vbNewLine
For i =1To array2.GetUpperBound(0)
msg &= array2(i)& vbNewLine
Next
MessageBox.Show(msg)
array.Sort(array)
array2.Sort(array2)For i =1To array.GetUpperBound(0)
msg2 &=array(i)& vbNewLine
Next
msg2 &= vbNewLine
For i =1To array2.GetUpperBound(0)
msg2 &= array2(i)& vbNewLine
Next
MessageBox.Show(msg2)EndSub
Handy Hints
Handy Hint 1
A check box is a useful way to find out what functions or tasks the user wants to show as completed or to use. A check box can be used to simply show that a task is complete or to make the program run a certain line of code.Handy Hint 2
Sort arrayControl Dictionary
IT Topic Presentation
Due to the size of the Silde Show for the IT topic I hvae had to upload it to the following websitePhotoshop CS4 Presentation
Attended Webinnar