I'm trying to get the value for a progessbar(in C#) from a variable I currently have, divided by 52, and multiplied by 100. This is the code I have, any suggestions to fix it ?
int value;
value = TestP1.corAns / 52 * 100;
ProgressBar pBar = new ProgressBar();
pBar.Value = value;
label2.Text = Convert.ToString(value) + "%";
See Question&Answers more detail:os