Imports System.
IO
Public Class AttendanceForm
Dim students(59) As String ' Assuming 60 students
Dim attendance(59) As Boolean ' True = Present, False = Absent
Private Sub AttendanceForm_Load(sender As Object, e As EventArgs) Handles [Link]
' Populate students array (you can load from DB/file)
For i = 0 To 59
students(i) = "Student " & (i + 1)
[Link](students(i))
Next
End Sub
Private Sub btnMark_Click(sender As Object, e As EventArgs) Handles [Link]
If [Link] <> -1 Then
Dim index As Integer = [Link]
attendance(index) = If([Link], True, False)
[Link](students(index) & " marked " & If(attendance(index), "Present", "Absent"))
End If
End Sub
Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles [Link]
' Save attendance to file (simple example)
Using writer As New StreamWriter("[Link]")
For i = 0 To 59
[Link](students(i) & "," & If(attendance(i), "Present", "Absent"))
Next
End Using
[Link]("Attendance saved!")
End Sub
End Class