Random Code bit for textbox values: no need to respond

weldos

Member
Joined
May 19, 2013
Messages
5
Programming Experience
1-3
Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
'clears each box back to zero so it does not stack.
onehun.Text = "0"
fifty.Text = "0"
twenty.Text = "0"
ten.Text = "0"
five.Text = "0"
two.Text = "0"
one.Text = "0"
pfive.Text = "0"
ptwenty.Text = "0"
pten.Text = "0"
pointfive.Text = "0"
'each of these if statements and loops are designed so that it checks if the'
'sum fits inside the ammount of money left to give if it fits it minuses the note from the sum and adds one to how many notes you need.'
Do
If TextBox2.Text / 100 >= 1 Then
onehun.Text = Val(onehun.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 100
End If
Loop Until TextBox2.Text / 100 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 50 >= 1 Then
fifty.Text = Val(fifty.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 50
End If
Loop Until TextBox2.Text / 50 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 20 >= 1 Then
twenty.Text = Val(twenty.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 20
End If
Loop Until TextBox2.Text / 20 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 10 >= 1 Then
ten.Text = Val(ten.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 10
End If
Loop Until TextBox2.Text / 10 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 5 >= 1 Then
five.Text = Val(five.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 5
End If
Loop Until TextBox2.Text / 5 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 2 >= 1 Then
two.Text = Val(two.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 2
End If
Loop Until TextBox2.Text / 2 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 1 >= 1 Then
one.Text = Val(one.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 1
End If
Loop Until TextBox2.Text / 1 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 0.5 >= 1 Then
pfive.Text = Val(pfive.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 0.5
End If
Loop Until TextBox2.Text / 0.5 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 0.2 >= 1 Then
ptwenty.Text = Val(ptwenty.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 0.2
End If
Loop Until TextBox2.Text / 0.2 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 0.1 >= 1 Then
pten.Text = Val(pten.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 0.1
End If
Loop Until TextBox2.Text / 0.1 < 1 Or
TextBox2.Text = "0"
Do
If TextBox2.Text / 0.05 >= 1 Then
pointfive.Text = Val(pointfive.Text) + 1
TextBox2.Text = Val(TextBox2.Text) - 0.05
End If
Loop Until TextBox2.Text / 0.05 < 1 Or
TextBox2.Text = "0"
 
End Sub

change code.jpg
 
Testing Tbale

Item TestedTest Data
Expected Results
cat 1 items
cat 2 items
cat 3 items
cat 4 items

Mentone staff disc
C1 = 4
C2 = 5
C3 = 7
C4 = 2

Mentone staff disc = yes
Cat 1 total= 16
Cat2 total =
Cat 3 total =



Testing Table: Triangle Solver
Item Tested
Test Data
Expected Results
Actual Result
2 sides given
S1=10, s2=6
H=11.66
A1=30.96
A2=59.04
H=11.66
A1=1.03
A2=0.54

*Convert to radians and back to degrees
2 sides given
S1=10, s2=6
H=11.66
A1=30.96
A2=59.04
H=11.66
A1=30.96
A2=59.04
1 side + hyp
S1=10.5, h=16
S2=12.07
A1=48.99
A2=41.01
S2=12.07
A1=48.99
A2=41.01

Efficiency

•Time
–Overall Time taken to complete the given task
–Using the software reduces the time a salesperson takes to calculate a sale. An Acceptable measure would be 3 seconds.
–Overall Time to enter data and create final quote is less than before.
•Cost
–Staffing levels dropped, or not increased with increased sales
–Less overtime (as sales staff take less time to complete one quote, therefore the last quote if the day doesn't take ages)
•Effort
–The Difficulty in calculating the total quote is much less.
•Resources


Effectiveness

Accuracy: Does it accurately calculate the cost of the quote 100% of the time?
Reliability: Does it work 100% of the time?
•Robustness X
•Portability X
•Maintainability ?
•Meets the user’s requirements

creating a evaluation criteria

?There are some simple criteria that might apply to most cases
?Efficiency – Time – reduces time to complete task
?Effectiveness – Accuracy – produces correct result 100% of the time
?To get full marks you need to
?Think carefully about the specific case
?Refer to the case study in your response



other efficiency mesures
?Time
?Takes less time to complete task
?Enter data
?Calculation
?Produce output
?Maintain system


?Cost
?Initial costs of purchase/development outweigh ongoing costs on current system
?Reduced wages costs due to automation
?Reduced waste/consumables


?Effort
?Number/hours of staff required
 
Back
Top