Under rating threshold (hideshow)
lstOutput.Items.Clear() 'clear listbox
Dim intCount As Integer 'declare variables
Dim dblPrice As Double
Dim dblQuantity As Double = 80
Dim strZone As String = "{0,-15}{1,10}{2,10}" 'make zone
dblPrice = 20 - 0.1 * dblQuantity
Under rating threshold (hideshow)
Dim strYear As String 'declare variables
Dim dblUsSales, dblWorldSales, dblUsRev, dblForeign, dblAverage As Double
'read from data file
Dim srPC As IO.StreamReader = IO.File.OpenText("pc.txt")
Dim strZone As String = "{0,-10}{1,-10}{2,-20}{3,-16}{4,-16}{5,-16}" 'make zone
lstOutput.Items.Add(String.Format(strZone, "Year", "US Sales", "Worldwide Sales", "US Revenues", "Pct Foreign", "Avg Rev"))
lstOutput.Items.Add("") 'display output
Do Until srPC.Peek = -1
Under rating threshold (hideshow)
lstOutput.Items.Clear() 'clear listbox
Dim intCount As Integer
Dim dblLoan As Double = 563
Dim strZone As String = "{0,-16} {1,10}" 'make zone
lstOutput.Items.Add(String.Format(strZone, "Starting Balance", FormatCurrency(dblLoan))) 'show starting balance
For intCount = 1 To 5
dblLoan = dblLoan * 1.01 - 116 'find balance
If dblLoan < 0 Then
dblLoan = 0
End If
lstOutput.Items.Add(String.Format(strZone, "After Month " & _
intCount, FormatCurrency(dblLoan))) 'show balance after each month
Next
Under rating threshold (hideshow)
lstOutput.Items.Clear() 'clear listbox
Dim intCount As Integer 'declare variables
Dim dblPrice As Double
Dim dblQuantity As Double = 80
Dim strZone As String = "{0,-15}{1,10}{2,10}" 'make zone
dblPrice = 20 - 0.1 * dblQuantity
lstOutput.Items.Add(String.Format(strZone, "Year", "Quantity", "Price")) 'show row
lstOutput.Items.Add("")
lstOutput.Items.Add(String.Format(strZone, "Starting Year", dblQuantity,
FormatCurrency(dblPrice))) 'd
Under rating threshold (hideshow)
-18 1i 18 1i,-18 a 8 23,-i 12 i 1o,7e 5d 7e 5m 79 5i,g5 bf gf bi,gb bi g1 bp fs bn,jv dr jv e3 jj e3##B ac 7v 4a,B 9o 7d 45,B 97 70 41,B 8o 6k 40,B 8l 6c 47,B 1u 2j 3f,B 1j 27 47 the best i can do with the balloon!