I am trying to use numeric updown to move back and forth through an array which stores the scores of typing tests taken by users. I’m honestly not even sure where to begin. I wrote some code but it doesn’t seem to be doing much of anything.
private void testUpDown_ValueChanged(object sender, EventArgs e)
{
foreach (testUpDown.Value = allTests[i])
{
prevErrorsBox = Errors.ToString();
prevWpmBox = WPM.ToString();
}
}
As you can imagine, it doesn’t do a whole lot. Should I be using a different control for this? This is being done with 3 tier design, if it matters. I will have to make this form load the values from a database as well.
Thanks in advance for any help.
You need to change the Index of the array with the Up/Down Control making sure that you can not exceed the bounds of the Array. See if something like this works for you.