Hi all, I'm currently doing this project where i have to create a program that let's the administrator manage students (and their tests.) I have decided to use Random Access file in this project.
because structures will need fixed lengths...i don't know how will i search through the students (a function of the program) when each student structure has a different length because of the number of tests they've done.
* I have created a variable in the aStudent structure so that i can know the number of tests a student has done...but don't know how to use it.
Here's my code:
Thanks~
because structures will need fixed lengths...i don't know how will i search through the students (a function of the program) when each student structure has a different length because of the number of tests they've done.
* I have created a variable in the aStudent structure so that i can know the number of tests a student has done...but don't know how to use it.
Here's my code:
VB.NET:
Public Class FormAdmin
Dim currentStudentName As String
Dim currentStudentID As Integer = 0
Dim filePath As String = Application.ExecutablePath + "StudentData.dat"
Dim oneStudent As aStudent
Structure aStudent
<VBFixedString(30)> Dim studentName As String
Dim studentID As Short
Dim totalTestDone As Short
Dim thisTest() As Test
End Structure
Structure Test
Dim testDate As System.DateTime
<VBFixedString(14)> Dim testType As String
Dim questionAnswered As Integer
Dim questionCorrect As Integer
dim timeTaken as integer
End Structure
Thanks~