Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Lines 1 5 9 - 1 6 4 won't execute even if input is 1 or 1 0 , please help resolve this Private Sub

Lines 159-164 won't execute even if input is 1 or 10, please help resolve this
Private Sub btnClose_Click(sender As Object, e As EventArgs) Handles
btnClose.Click
'Close program
Me.Close()
End Sub
Private Sub btnRestart_Click(sender As Object, e As EventArgs) Handles btnRestart.Click
'Reset program
txtGPA.Text =""
txtScore.Text =""
txtOutput.Visible = False
radSAT1.Checked = False
radSAT2.Checked = False
radSAT3.Checked = False
radSAT4.Checked = False
radSAT5.Checked = False
radHS1.Checked = False
radHS2.Checked = False
radHS3.Checked = False
radHS4.Checked = False
radHS5.Checked = False
radHS6.Checked = False
radCD1.Checked = False
radCD2.Checked = False
radCD3.Checked = False
radCD4.Checked = False
radCD5.Checked = False
radCD6.Checked = False
radCD7.Checked = False
chkGeo1.Checked = False
chkGeo2.Checked = False
chkAlumni1.Checked = False
chkAlumni2.Checked = False
radEssay1.Checked = False
radEssay2.Checked = False
radEssay3.Checked = False
chkLS1.Checked = False
chkLS2.Checked = False
chkLS3.Checked = False
radMisc1.Checked = False
radMisc2.Checked = False
radMisc3.Checked = False
radMisc4.Checked = False
End Sub
Private Sub btnCompute_Click(sender As Object, e As EventArgs) Handles btnCompute.Click
Dim dblGPA As Double
Dim dblScore As Double
Dim dblSAT As Double
Dim dblHS As Double
Dim dblCD As Double
Dim dblGEO As Double
Dim dblALUM As Double
Dim dblESSAY As Double
Dim dblLS As Double
Dim dblMISC As Double
Dim dblUncapped As Double
Dim dblCapped As Double
Dim dblTotScore As Double
'Display Error Message
dblGPA = CDbl(txtGPA.Text)
If dblGPA 2.0 Or dblGPA >4.0 Then
txtScore.Text =""
txtOutput.Visible = True
txtOutput.Text = "GPA must be between 2.0 and 4.0."
End If
'Calculate Score
dblScore = dblGPA *20
txtScore.Text = dblScore
'Add total points
If radSAT1.Checked = True Then
dblSAT = radSAT1.Tag
End If
If radSAT2.Checked = True Then
dblSAT = radSAT2.Tag
End If
If radSAT3.Checked = True Then
dblSAT = radSAT3.Tag
End If
If radSAT4.Checked = True Then
dblSAT = radSAT4.Tag
End If
If radSAT5.Checked = True Then
dblSAT = radSAT5.Tag
End If
If radHS1.Checked = True Then
dblHS = radHS1.Tag
End If
If radHS2.Checked = True Then
dblHS = radHS2.Tag
End If
If radHS3.Checked = True Then
dblHS = radHS3.Tag
End If
If radHS4.Checked = True Then
dblHS = radHS4.Tag
End If
If radHS5.Checked = True Then
dblHS = radHS5.Tag
End If
If radHS6.Checked = True Then
dblHS = radHS6.Tag
End If
If radCD1.Checked = True Then
dblCD = radCD1.Tag
End If
If radCD2.Checked = True Then
dblCD = radCD2.Tag
End If
If radCD3.Checked = True Then
dblCD = radCD3.Tag
End If
If radCD4.Checked = True Then
dblCD = radCD4.Tag
End If
If radCD5.Checked = True Then
dblCD = radCD5.Tag
End If
If radCD6.Checked = True Then
dblCD = radCD6.Tag
End If
If radCD7.Checked = True Then
dblCD = radCD7.Tag
End If
If chkGeo1.Checked = True Then
dblGEO = chkGeo1.Tag
End If
If chkGeo2.Checked = True Then
dblGEO = chkGeo2.Tag
End If
If chkGeo3.Checked = True Then
dblGEO = chkGeo3.Tag
End If
If chkAlumni1.Checked = True Then
dblALUM = chkAlumni1.Tag
End If
If chkAlumni2.Checked = True Then
dblALUM = chkAlumni2.Tag
End If
If radEssay1.Checked = True Then
dblESSAY = radEssay1.Tag
End If
If radEssay2.Checked = True Then
dblESSAY = radEssay2.Tag
End If
If radEssay3.Checked = True Then
dblESSAY = radEssay3.Tag
End If
If chkLS1.Checked = True Then
dblLS = chkLS1.Tag
End If
If chkLS2.Checked = True Then
dblLS = chkLS2.Tag
End If
If chkLS3.Checked = True Then
dblLS = chkLS3.Tag
End If
If radMisc1.Checked = True Then
dblMISC = radMisc1.Tag
End If
If radMisc2.Checked = True Then
dblMISC = radMisc2.Tag
End If
If radMisc3.Checked = True Then
dblMISC = radMisc3.Tag
End If
If radMisc4.Checked = True Then
dblMISC = radMisc4.Tag
End If
'Calculate total points for top half
dblUncapped = dblSAT + dblHS + dblCD
'Calculate total points for bottom half options
dblCapped = dblGEO + dblALUM + dblESSAY + dblLS + dblMISC
If dblCapped >=40 Then
dblCapped =40
End If
dblTotScore += dblScore + dblCapped + dblUncapped
If dblTotScore >=100 Then
txtOutput.Visible = True
txtOutput.Text = "Total Points: " & dblTotScore & " Admitted!"
Else
txtOutput.Visible = True
txtOutput.Text = dblTotScore & " Rejected"
End if
Here is a picture of the correct output
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And Implementation

Authors: Edward Sciore

2nd Edition

3030338355, 978-3030338350

More Books

Students also viewed these Databases questions

Question

Define Decision making

Answered: 1 week ago

Question

What are the major social responsibilities of business managers ?

Answered: 1 week ago

Question

What are the skills of management ?

Answered: 1 week ago

Question

Organizing Your Speech Points

Answered: 1 week ago