Open kwakevainen opened 4 years ago
I'm actually getting this error every time I click save?
The data is not saving to MatchData.csv
See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog box.
** Exception Text ** System.IndexOutOfRangeException: Index was outside the bounds of the array. at FRCScouting.RobotData.SaveData(String dataFile, Int32 matchNumber) in C:\Users\Katie\Documents\Robotics\2020-Scouting\FRCScouting\RobotData.cs:line 105 at FRCScouting.Form1.btnSaveMatchData_Click(Object sender, EventArgs e) in C:\Users\Katie\Documents\Robotics\2020-Scouting\FRCScouting\Form1.cs:line 329 at System.Windows.Forms.Control.OnClick(EventArgs e) at System.Windows.Forms.Button.OnClick(EventArgs e) at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent) at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ButtonBase.WndProc(Message& m) at System.Windows.Forms.Button.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
When saving the first match with an empty MatchData.csv the following exception is thrown: " ** Exception Text ** System.IndexOutOfRangeException: Index was outside the bounds of the array. at FRCScouting.RobotData.SaveData(String dataFile, Int32 matchNumber) in C:\Users\Katie\Documents\Robotics\2020-Scouting\FRCScouting\RobotData.cs:line 103 at FRCScouting.Form1.btnSaveMatchData_Click(Object sender, EventArgs e) in C:\Users\Katie\Documents\Robotics\2020-Scouting\FRCScouting\Form1.cs:line 329 at System.Windows.Forms.Control.OnClick(EventArgs e) at System.Windows.Forms.Button.OnClick(EventArgs e) at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent) at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ButtonBase.WndProc(Message& m)"