Click here to Skip to main content
15,918,808 members
Home / Discussions / Visual Basic
   

Visual Basic

 
Questionbeginner here. Pin
bjk8821-Oct-07 13:11
bjk8821-Oct-07 13:11 
AnswerRe: beginner here. Pin
Colin Angus Mackay21-Oct-07 13:23
Colin Angus Mackay21-Oct-07 13:23 
GeneralRe: beginner here. Pin
bjk8821-Oct-07 13:28
bjk8821-Oct-07 13:28 
GeneralRe: beginner here. Pin
Colin Angus Mackay21-Oct-07 13:33
Colin Angus Mackay21-Oct-07 13:33 
GeneralRe: beginner here. Pin
bjk8821-Oct-07 13:42
bjk8821-Oct-07 13:42 
GeneralRe: beginner here. Pin
Colin Angus Mackay21-Oct-07 13:50
Colin Angus Mackay21-Oct-07 13:50 
GeneralRe: beginner here. Pin
bjk8821-Oct-07 13:58
bjk8821-Oct-07 13:58 
AnswerRe: beginner here. Pin
Guffa21-Oct-07 22:35
Guffa21-Oct-07 22:35 
bjk88 wrote:
lstbox.Items.Add(String.Format(fmtStr, "Team", "Played", "Won", "Drawn", "Lost", "Points", "AveAttendance", "AveIncome", "%Won"))


You can't use string values with a format that expects numeric values.

bjk88 wrote:
won = sr.ReadLine


This is an implicit conversion equivalent to:

won = Convert.ToInt32(Double.Parse(sr.ReadLine))

This might not be exactly what you want. You might rather want to use Option Explicit On (to avoid unintended conversions), and do the conversions youself, so that you see what actually happens.

bjk88 wrote:
lstbox.Items.Add(String.Format(fmtStr, team, won, drawn, lost, points, aveA, aveI, perc))


You haven't assigned any value to the perc variable.

---
"Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things."
-- Douglas Adams

GeneralRe: beginner here. Pin
bjk8821-Oct-07 22:48
bjk8821-Oct-07 22:48 
GeneralRe: beginner here. Pin
Guffa21-Oct-07 23:01
Guffa21-Oct-07 23:01 
GeneralRe: beginner here. Pin
bjk8821-Oct-07 23:12
bjk8821-Oct-07 23:12 
GeneralRe: beginner here. Pin
Guffa21-Oct-07 23:48
Guffa21-Oct-07 23:48 
GeneralRe: beginner here. Pin
bjk8822-Oct-07 0:04
bjk8822-Oct-07 0:04 
AnswerRe: beginner here. Pin
Guffa22-Oct-07 0:11
Guffa22-Oct-07 0:11 
GeneralRe: beginner here. Pin
bjk8822-Oct-07 0:22
bjk8822-Oct-07 0:22 
GeneralRe: beginner here. Pin
bjk8822-Oct-07 0:44
bjk8822-Oct-07 0:44 
AnswerRe: beginner here. Pin
Guffa22-Oct-07 1:59
Guffa22-Oct-07 1:59 
Questionqube rotation Pin
bapu288921-Oct-07 7:43
bapu288921-Oct-07 7:43 
AnswerRe: qube rotation Pin
Guffa21-Oct-07 10:00
Guffa21-Oct-07 10:00 
AnswerRe: qube rotation Pin
Christian Graus21-Oct-07 12:05
protectorChristian Graus21-Oct-07 12:05 
QuestionVB Text to WAV, Text to Speech, Voice recognition Pin
Robert from Florida21-Oct-07 3:42
Robert from Florida21-Oct-07 3:42 
AnswerRe: VB Text to WAV, Text to Speech, Voice recognition Pin
Christian Graus21-Oct-07 12:11
protectorChristian Graus21-Oct-07 12:11 
QuestionCPU Usage? Pin
AliAmjad21-Oct-07 3:25
AliAmjad21-Oct-07 3:25 
AnswerRe: CPU Usage? Pin
Paul Conrad21-Oct-07 8:52
professionalPaul Conrad21-Oct-07 8:52 
GeneralRe: CPU Usage? Pin
AliAmjad21-Oct-07 9:19
AliAmjad21-Oct-07 9:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.