Vb Net Lab Programs For Bca Students Apr 2026

Sub Main() Dim tasks As New List(Of Task) While True Console.WriteLine("1. Add Task") Console.WriteLine("2. Delete Task") Console.WriteLine("3. Mark Task as Completed") Console.WriteLine("4.

Imports System.Collections.Generic Module StudentInfo Sub Main() Dim students As New List(Of Student) While True Console.WriteLine("1. Add Student") Console.WriteLine("2. Delete Student") Console.WriteLine("3. Display Students") Console.WriteLine("4. Exit") Dim choice As Integer = Convert.ToInt32(Console.ReadLine()) Select Case choice Case 1 AddStudent(students) Case 2 DeleteStudent(students) Case 3 DisplayStudents(students) Case 4 Exit While Case Else Console.WriteLine("Invalid choice") End Select End While End Sub Sub AddStudent(ByRef students As List(Of Student)) Dim name As String = Console.ReadLine() Dim rollNumber As Integer = Convert.ToInt32(Console.ReadLine()) Dim marks As Double = Convert.ToDouble(Console.ReadLine()) Dim student As New Student(name, rollNumber, marks) students.Add(student) End Sub Sub DeleteStudent(ByRef students As List(Of Student)) Dim rollNumber As Integer = Convert.ToInt32(Console.ReadLine()) For i As Integer = 0 To students.Count - 1 If students(i).RollNumber = rollNumber Then students.RemoveAt(i) Exit For End If Next End Sub Sub DisplayStudents(ByVal students As List(Of Student)) For Each student As Student In students Console.WriteLine(student.Name & " " & student.RollNumber & " " & student.Marks) Next End Sub End Module Public Class Student Public Property Name As String Public Property RollNumber As Integer Public Property Marks As Double Public Sub New(name As String, rollNumber As Integer, marks As Double) Me.Name = name Me.RollNumber = rollNumber Me.Marks = marks End Sub End Class Create a simple to-do list app that allows users to add, delete, and mark tasks as completed. vb net lab programs for bca students

Module ToDoList

Here are some essential VB.NET lab programs for BCA students, covering various topics and concepts: Create a simple calculator program that takes two numbers as input and performs basic arithmetic operations (addition, subtraction, multiplication, and division). Sub Main() Dim tasks As New List(Of Task) While True Console