Gokul 1
Gokul 1
Gokul 1
Submitted by
GOWTHAM.A
(Reg.No:2122K2251)
SATHYAMANGALAM-638503
MARCH-2024
CERTIFICATE
This is to certify that the project report entitled, “QUIZ APPLICATION” submitted
to the Bharathiar University in partial fulfillment of the requirements for the award of the
Degree of Bachelor of Science in Computer Science is a record of original project work done
by GOWTHAM.A(Reg. No: 2122K2251) during the period (2023- 2024) of her study in the
PG and Research Department of Computer Science at Kaamadhenu Arts and Science
College, Sathyamangalam under his supervision and guidance and that this project report has
not formed the basis for the award of any Degree / Diploma / Associate ship / Fellowship or
other similar title to any candidate of any University.
Countersigned
The completion of this project was not just because of my ability but there are some
well-wishers behind it. I am always thankful to them.
This project would not happen without the help of many people. I express my sincere
Thanks to our Chairman Thiru. R. PERUMALSAMY Avl., Kaamadhenu Arts and Science
College, Sathyamangalam for establishing my studies in this campus.
1 INTRODUCTION 1
2
1.1 ABOUT THE PROJECT 1
3
1.2 SYSTEM SPECIFICATION 2
4
1.2.1 HARDWARE CONFIGURATION 2
5
1.2.2 SOFTWARE SPECIFICATION 2
6 SYSTEM STUDY 9
7
2.1 EXISTING SYSTEM 9
8
2.1.1 DRAWBACKS 9
9
2.2 PROPOSED SYSTEM 10
10
2.2.1 FEATURES 10
Quiz application is a web application that establishes a network between the institutes
and the students. Institutes enter on the site the questions they want in the exam. These questions
are displayed as a test to the eligible students. The answers enter by the students are then
evaluated and their score is calculated and saved. This score then can be accessed by the
institutes to determine the passes students or to evaluate their performance. quiz application
provides the platform but does not directly participate in, nor is it involved in any tests
conducted. Questions are posted not by the site, but users of the site. The site requires an institute
to register before posting the questions. The site has an administrator who keeps an eye on the
overall functioning of the system. The site gets revenue by charging the institutes each time they
want to conduct the exam. The system entitled “Quiz Application” is application software,
which aims at providing services to the institutes and providing them with an option of selecting
the eligible students by themselves. It is developed by using Model technology and related C#
and Sql-Server.
Currently most of the Examination like organizational recruitment, University class test
are paper based, which costs time and resources. Questionnaire is developed, printed, and then
collect data, entry, editing, cleaning, which time consuming and costly. Proposed application is
the starting for avoid those circumstances which are been currently faced by any organization.
1
1.1 SYSTEM SPECIFICATION
th
• System : Inter i5 5 Gen.
• Mouse : Logitech.
• Ram :4GB.
2
SOFTWARE DESCRIPTION
Microsoft .NET is a set of Microsoft software technologies for rapidly building and
integrating XML Web services, Microsoft Windows-based applications, and Web solutions. The
.NET Framework is a language-neutral platform for writing programs that can easily and
securely interoperate. There’s no language barrier with .NET: there are numerous languages
available to the developer including Managed C++, C#, Visual Basic and Java Script.
The .NET framework provides the foundation for components to interact seamlessly,
whether locally or remotely on different platforms. It standardizes common data types and
communications protocols so that components created in different languages can easily
interoperate.
“.NET” is also the collective name given to various software components built upon the
.NET platform. These will be both products (Visual Studio.NET and Windows.NET Server, for
instance) and services (like Passport, .NET My Services, and so on).
The CLR is described as the “execution engine” of .NET. It provides the environment
within which programs run. The most important features are
Loading and executing programs, with version control and other such features.
The following features of the .NET framework are also worth description:
3
MANAGED CODE
The code that targets .NET, and which contains certain extra Information - “metadata” -
to describe itself. Whilst both managed and unmanaged code can run in the runtime, only
managed code contains the information that allows the CLR to guarantee, for instance, safe
execution and interoperability.
MANAGED DATA
Managed Code comes Managed Data CLR provides memory allocation and Deal location
facilities, and garbage collection. Some .NET languages use Managed Data by default, such as
C#, Visual Basic.NET and JScript.NET, whereas others, namely C++, do not. Targeting CLR
can, depending on the language you’re using, impose certain constraints on the features
available. As with managed and unmanaged code, one can have both managed and unmanaged
data in .NET applications - data that doesn’t get garbage collected but instead is looked after by
unmanaged code.
The CLR uses something called the Common Type System (CTS) to strictly enforce
type-safety. This ensures that all classes are compatible with each other, by describing types in a
common way. CTS define how types work within the runtime, which enables types in one
language to interoperate with types in another language, including cross-language exception
handling. As well as ensuring that types are only used in appropriate ways, the runtime also
ensures that code doesn’t attempt to access memory that hasn’t been allocated to it.
The CLR provides built-in support for language interoperability. To ensure that you can
develop managed code that can be fully used by developers using any programming language, a
set of language features and rules for using them called the Common Language Specification
(CLS) has been defined. Components that follow these rules and expose only CLS features are
considered CLS-compliant.
4
THE CLASS LIBRARY
.NET provides a single-rooted hierarchy of classes, containing over 7000 types. The root
of the namespace is called System; this contains basic types like Byte, Double, Boolean, and
String, as well as Object. All objects derive from System. Object. As well as objects, there are
value types. Value types can be allocated on the stack, which can provide useful flexibility.
There are also efficient means of converting value types to object types if and when necessary.
The set of classes is pretty comprehensive, providing collections, file, screen, and
network I/O, threading, and so on, as well as XML and database connectivity. The class library is
subdivided into a number of sets (or namespaces), each providing distinct areas of functionality,
with dependencies between the namespaces kept to a minimum.
The multi-language capability of the .NET Framework and Visual Studio .NET enables
developers to use their existing programming skills to build all types of applications and XML
Web services. The .NET framework supports new versions of Microsoft’s old favorites Visual
Basic and C++ (as VB.NET and Managed C++), but there are also a number of new additions to
the family.
Visual Basic .NET has been updated to include many new and improved language
features that make it a powerful object-oriented programming language. These features include
inheritance, interfaces, and overloading, among others. Visual Basic also now supports
structured exception handling, custom attributes and also supports multi-threading.
Visual Basic .NET is also CLS compliant, which means that any CLS-compliant
language can use the classes, objects, and components you create in Visual Basic .NET.
Managed Extensions for C++ and attributed programming are just some of the
enhancements made to the C++ language. Managed Extensions simplify the task of migrating
existing C++ applications to the new .NET Framework.
C# is Microsoft’s new language. It’s a C-style language that is essentially “C++ for Rapid
Application Development”. Unlike other languages, its specification is just the grammar of the
language. It has no standard library of its own, and instead has been designed with the intention
of using the .NET libraries as its own. Microsoft Visual J# .NET provides the easiest transition
for Java-language developers into the world of XML Web Services and dramatically.
5
improves the interoperability of Java-language programs with existing software written in a
variety of other programming languages.
Active State has created Visual Perl and Visual Python, which enable .NET-aware
applications to be built in either Perl or Python. Both products can be integrated into the Visual
Studio .NET environment. Visual Perl includes support for Active State’s Perl Dev Kit.Other
languages for which .NET compilers are available include
Operating System
Fig.5.3.1.Net Framework
C#.NET is also compliant with CLS (Common Language Specification) and supports
structured exception handling. CLS is set of rules and constructs that are supported by the CLR
(Common Language Runtime). CLR is the runtime environment provided by the .NET
Framework; it manages the execution of the code and also makes the development process easier
by providing services.
Constructors are used to initialize objects, whereas destructors are used to destroy them.
In other words, destructors are used to release the resources allocated to the object. In C#.NET
the sub finalize procedure is available. The sub finalize procedure is used to complete the tasks
that must be performed when an object is destroyed. The sub finalize procedure is called
automatically when an object is destroyed. In addition, the sub finalize procedure can be called
only from the class it belongs to or from derived classes.
6
GARBAGE COLLECTION
Garbage Collection is another new feature in C#.NET. The .NET Framework monitors
allocated resources, such as objects and variables. In addition, the .NET Framework
automatically releases memory for reuse by destroying objects that are no longer in use.
In C#.NET, the garbage collector checks for the objects that are not currently in use by
applications. When the garbage collector comes across an object that is marked for garbage
collection, it releases the memory occupied by the object.
OVERLOADING
MULTITHREADING
C#.NET supports structured handling, which enables us to detect and remove errors at
runtime. In C#.NET, we need to use Try…Catch…Finally statements to create exception
handlers. Using Try…Catch…Finally statements, we can create robust and effective exception
handlers to improve the performance of our application.
7
FEATURES OF SQL-SERVER
The OLAP Services feature available in SQL Server version 7.0 is now called SQL
Server 2000 Analysis Services. The term OLAP Services has been replaced with the term
Analysis Services. Analysis Services also includes a new data mining component. The
Repository component available in SQL Server version 7.0 is now called Microsoft SQL Server
2000 Meta Data Services. References to the component now use the term Meta Data Services.
The term repository is used only in reference to the repository engine within Meta Data
Services.SQL-SERVER database consist of six type of objects.
TABLE
VIEWS OF TABLE
Design View
Datasheet View
DESIGN VIEW
To build or modify the structure of a table we work in the table design view. We can
specify what kind of data will be hold.
DATASHEET VIEW
To add, edit or analyses the data itself we work in tables datasheet view mode.
QUERY
A query is a question that has to be asked the data. Access gathers data that answers the
question from one or more table. The data that make up the answer is either dynaset (if you edit
it) or a snapshot (it cannot be edited).Each time we run query, we get latest information in the
dynaset.
8
SYSTEM STUDY
The existing application is to not a user friendly platform by manual effort. In past
days we have seen that quiz were taken manually. Especially in the time of this pandemic use
of such applications is highly appreciated as schools and colleges are very much affected.
The manual handling of the record is time consuming and highly prone to error. The purpose
of this project is to automate or make online, the process of day-to-day activities like question
preparation, student registration and etc.
2.1.1 DRAWBACKS
• Time-consuming job.
• Lack of security for the records, anyone disarrange the records of your system
• If someone want to check the details of the available doctors the previous system
does not provide any necessary detail of this type.
9
2.2 PROPOSED SYSTEM
The purpose of the project is to provide online facility to Institutes to conduct online
exams and to Students to give online exams. Institutes can enter and edit the questions along
with the students list. Also they can view the result. Students can login and give their
respective exams and view their score then and there. Others can view sample papers to get
look and feel of the online examination system. This online quiz website reduces the manual
work, maintaining accuracy, increasing efficiency and saving time. Also institutes need not
go to develop a new software each time, instead they just register and conduct a test. For
students, it saves time of going to far away centers and also they can view their result.
2.2.1 FEATURES
10
SYSTEM DESIGN AND DEVELOPMENT
Information systems in business are file and database oriented. Data are accumulated
into files that are processed or maintained by the system. The systems analyst is responsible
for designing files, determining their contents and selecting a method for organizing the data.
The file design is the last phase that indicates the final system and process of the final
system. The database tables where designed by using all the necessary fields in compact
manner.
All the input screens in the system are user-friendly and understandable format. Also
the sizes of all the screens are standardized.
Icons designed in this system are brief, compact and self-explanatory. The icons are
sharp and novice user can invoke the system.
Reports generated here give the minute information, which helps the manager to take
vital decisions.
Both forms and reports are the product of input and output design and are business
document consisting of specified data. The main difference is that forms provide fields for
data input but reports are purely used for reading. For example, order forms, employment and
credit application, etc.
In an information system, input is the raw data that is processed to produce output.
During the input design, the developers must consider the input devices such as PC, MICR,
OMR, etc.
Therefore, the quality of system input determines the quality of system output. Well
designed input forms and screens have following properties −
It should serve specific purpose effectively such as storing, recording, and retrieving
the information.
11
It should be easy to fill and straightforward.
All these objectives are obtained using the knowledge of basic design principles
regarding
To design source documents for data capture or devise other data capture methods
To design input data records, data entry screens, user interface screens, etc.
Audit trails for data entry and other system operations are created using transaction
logs which gives a record of all changes introduced in the database to provide security and
means of recovery in case of any failure.
Input data of a system may not be necessarily is raw data captured in the system
from scratch. These can also be the output of another system or subsystem. The design of
Input covers all the phases of input from the creation of initial data to actual entering of the
data to the system for processing. The design of inputs involves identifying the data
needed, specifying the characteristics of each data item, capturing and preparing data for
computer processing and, ensuring correctness of data.
12
3.3 OUTPUT DESIGN
The design of output is the most important task of any system. During output design,
developers identify the type of outputs needed, and consider the necessary output controls
and prototype report layouts.
To develop output design that serves the intended purpose and eliminates the
production of unwanted output.
To develop the output design that meets the end users requirements.
To form the output in appropriate format and direct it to the right person.
External Outputs
Manufacturers create and design external outputs for printers. External outputs enable
the system to leave the trigger actions on the part of their recipients or confirm actions to
their recipients.
Some of the external outputs are designed as turnaround outputs, which are
implemented as a form and re-enter the system as an input.
Internal outputs
Internal outputs are present inside the system, and used by end-users and managers.
They support the management in decision making and reporting.
Detailed Reports − They contain present information which has almost no filtering
or restriction generated to assist management planning and control.
Summary Reports − They contain trends and potential problems which are
categorized and summarized that are generated for managers who do not want
details.
Exception Reports − They contain exceptions, filtered data to some condition or
standard before presenting it to the manager, as information.
13
Output Integrity Controls
Output integrity controls include routing codes to identify the receiving system, and
verification messages to confirm successful receipt of messages that are handled by network
protocol.
Printed or screen-format reports should include a date/time for report printing and the
data. Multipage reports contain report title or description, and pagination. Pre-printed forms
usually include a version number and effective date.
The term database design can be used to describe many different parts of the design of
an overall database system. Principally, and most correctly, it can be thought of as the logical
design of the base data structures used to store the data. In the relational model these are the
tables and views. In an object database the entities and relationships map directly to object
classes and named relationships. However, the term database design could also be used to
apply to the overall process of designing, not just the base data structures, but also the forms
and queries used as part of the overall database application within the database management
system (DBMS).
The purpose of System Design is to create a technical solution that satisfies the
functional requirements for the system. In the project lifecycle there should be a Functional
Specification, written primarily in business terminology, containing a complete description of
the operational needs of the various organizational entities that will use the new system.
Design is the first step in the development phase for any engineered product or
system. The designer’s goal is to produce a model or representation of an entity that will later
be built. At Beginning, once system requirement have been specified and analyzed, system
design is the first of the three technical activities -design, code and test that is required to
build and verify software.
14
The importance can be stated with a single word “Quality”. Design is the place where
quality is fostered in software development. Design provides us with representations of
software that can assess for quality. Design is the only way that we can accurately translate a
customer’s view into a finished software product or system.
During design, progressive refinement of data structure, program structure, and procedural
details are developed reviewed and documented. System design can be viewed from either
technical or project management perspective.
Login
The login Module is used to allow the authorized user to enter in the system.
Unauthorized users are restricted to enter in the system. Authentication is done by using a
valid user id and password. The administrator should be able to to add, update and delete
questions, answers and keywords.
Admin
- Question Entry
- Subject Entry
- Exam Details
- Ranking
- View User Details
User
- User Registration
- Selection Subject
- Attend Quiz
- View Result and Ranking
Admin
Question Entry
This module adding the question and set the answer. Answer contains four options.
15
Subject Entry
This module adding quiz subject details like as subject name, subject id and total
marks.
Quiz Details
This module contain quiz details like as subject id, subject name, Total Questions,
Minimum Mark and total mark.
Ranking
User
User Register
This module add the user particulars like user name, email id and password. If the
register successfully and go to the quiz.
Select Subject
Attend Quiz
After user select the subject and displays question details. User select the answer to all
questions.
This module user view the quiz exam result and ranking.
16
TESTING AND IMPLEMENTATION
Testing is the process or activity that checks the functionality and correctness of
software according to specified user requirements in order to improve the quality and
reliability of system. It is an expensive, time consuming, and critical approach in system
development which requires proper planning of overall testing process.
A successful test is one that finds the errors. It executes the program with explicit
intention of finding error, i.e., making the program fail. It is a process of evaluating system
with an intention of creating a strong system and mainly focuses on the weak areas of the
system or software.
The software, has been developed, has to be tested to prove its validity Testing is
considered to be the least creative phase of the whole cycle of the system design in the real
sense it is the phase, it helps to bring out the creativity of the other phase, and make it shine.
Mail Server was tested along the following guidelines to prove its validity .It was tested using
the following two techniques of the software testing.
Testing is done at two level-testing of individual modules and testing the entire
system. During the system testing, the system is used experimentally to ensure that the
software will run according to the specifications and in the way the user expects. Each test
case is designed with the intent of finding errors in the way the system will process it.
Testing plays a very critical roll in determining the reliability and efficiency of
software and hence is a very important stage in software development. Software testing is
done at different levels.
Unit Testing
Integration Testing
Validation Testing
Acceptance Testing
Test Cases
17
Unit Testing
Also known as Program Testing, it is a type of testing where the analyst tests or
focuses on each program or module independently. It is carried out with the intention of
executing each statement of the module at least once.
Integration Testing
In Integration Testing, the analyst tests multiple module working together. It is used to
find discrepancies between the system and its original objective, current specifications, and
systems documentation.
Here the analysts are try to find areas where modules have been designed with
different specifications for data length, type, and data element name.
It verifies that file sizes are adequate and that indices have been built properly.
Validation Testing
Validation testing is the process of ensuring if the tested and developed software
satisfies the client /user needs. The business requirement logic or scenarios have to be tested
in detail. All the critical functionalities of an application must be tested here. As a tester, it is
always important to know how to verify the business logic or scenarios that are given to you.
One such method that helps in detail evaluation of the functionalities is the Validation
Process. Whenever you are asked to perform a validation test, it takes a great responsibility as
you need to test all the critical business requirements based on the user needs. There should
not be even a single miss on the requirements asked by the user. Hence a keen knowledge on
validation testing is much important
Acceptance Testing
The objective of the acceptance test is to tell the user about the validity and reliability
of the system. It verifies whether the system operates as specified and the integration of
important data is maintained. User motivation is very important for the successful
performance of the system.
18
All the modules were tested individually using both test data and live data. After each
module was ascertained that it was working correctly and it had been “integrated” with the
system. Again the system was tested as a whole. We hold the system tested with different
types of users. The System Design, Data Flow Diagram, procedures etc. were well
documented so that the system can be easily maintained and upgraded by any computer
professional at a later.
Acceptance testing is done with live data provided by the client to ensure that the
software works satisfactorily. It focuses on the external behavior of the system.
Test Cases
Again this software testing strategy has two different approaches namely the top down
approach in which the integration is carried out from the top level module to the bottom and
the bottom up approach in which the integration is carried out the low level modules to the
top. The module was tested using the bottom up approach by introducing stubs for the top-
level functions. It is used top identify the errors in the interfaces, the errors in passing the
parameters, between the functions and to correct them.
A different set of activities that ensures the software that has been built is traceable to
customer requirements. Errors are corrected and a final series of test i.e., validation succeeds
when the software function in a manner that can be reasonably accepted by the customer.
Implementation allows the users to take over its operation for use and evaluation. It
involves training the users to handle the system and plan for a smooth conversion.
Training
The personnel in the system must know in detail what their roles will be, how they
can use the system, and what the system will or will not do. The success or failure of
19
welldesigned and technically elegant systems can depend on the way they are operated and
used.
Systems operators must be trained properly such that they can handle all possible
operations, both routine and extraordinary. The operators should be trained in what common
malfunctions may occur, how to recognize them, and what steps to take when they come.
Training also involves familiarization with run procedures, which involves working through
the sequence of activities needed to use a new system.
User Training
User training involves how to operate the equipment, troubleshooting the system
problem, determining whether a problem that arose is caused by the equipment or
software.
Most user training deals with the operation of the system itself. The training courses
must be designed to help the user with fast mobilization for the organization.
Training Guidelines
20
CONCLUSION
This project concluded that this web application works as per the need and
requirement of the client and is user friendly. Also this mini project helped me to understand
the design, code and implementation processes which are performed while making any
project. Many concepts were revised and many of them were very new which were learnt in
making of this web application. This system is more flexible and a future enhancement is
possible without any complication. The following points concluded the discussions done so
far from the working experience with the software.
21
BIBLIOGRAPHY
BOOK REFERENCES
5. RogerS.Pressman,(2008)B“SOFTWAREENGINEERING
PRACTITIONERS APPROACH” Mc Graw Hill International Edition, VI
Edition.
WEB REFERENCES
1. www.w3school.com
2. www.vbtutor.in
3. www.google.com/dotnet
22
APPENDICES
Login
Admin User
No
Sub_Det Add subject
Reg
Add
Qus_Det
Questions Exam
View Result
Result and
Rank
Res_Det
23
B. TABLE STRUCTURE
24
Table Name : Rank
25
C. SAMPLE CODING
Imports System.Data
Imports System.Data.OleDb
Imports System.Drawing.Printing
Imports System.Drawing.Printing.PrinterSettings
Imports System.IO
Imports System.Drawing.Image
Imports System.Windows
Imports KeepAutomation.Barcode.Windows
Imports KeepAutomation.Barcode
Imports KeepAutomation.Barcode.Bean
Imports TarCode.Barcode.Control.LinearBarcode
Imports TarCode.Barcode
Imports TarCode.Barcode.Control.LinearWinForm
Public Class Form4
Dim cmd As OleDbCommand
Private Sub Form4_Load(sender As Object, e As EventArgs) Handles MyBase.Load
If cn.State <> ConnectionState.Open Then cn.Open()
End Sub
Dim t1(1000)
Dim decode, T2 As String
Dim i, len As Integer
T2 = TextBox3.Text
len = T2.Length
For i = 0 To len - 1
av = Convert.ToByte(T2(i))
TextBox4.Text = TextBox4.Text & av
Next
ElseIf ComboBox1.Text = "Binary" Then
Timer1.Start()
Dim Temp As String = ""
Dim txtBuilder As New System.Text.StringBuilder
For Each Character As Byte In
System.Text.ASCIIEncoding.ASCII.GetBytes(TextBox3.Text)
txtBuilder.Append(Convert.ToString(Character, 2).PadLeft(8, "0"))
txtBuilder.Append(" ")
Next
Temp = txtBuilder.ToString.Substring(0, txtBuilder.ToString.Length - 0)
TextBox4.Text = Temp
End If
End Sub
26
Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs)
Handles ComboBox1.SelectedIndexChanged
TextBox2.Text = ComboBox1.Text
End Sub
cn.Close()
If MsgBox("FINISH", MsgBoxStyle.OkOnly, "") = MsgBoxResult.Ok Then
Label5.Visible = False
TextBox4.Visible = False
End If
End If
End Sub
End Class
Imports System.Windows.Forms
Imports System.Data.OleDb
Imports System.Data
Imports System.Math
Imports System.Drawing
Imports System.IO
Public Class Form5
Dim cmd As OleDbCommand
Private Sub Form5_Load(sender As Object, e As EventArgs) Handles MyBase.Load
If cn.State <> ConnectionState.Open Then cn.Open()
End Sub
While dr.Read
TextBox1.Text = dr(3).ToString
End While
27
dr.Close()
cn.Close()
End Sub
While dr.Read
TextBox3.Text = dr(2).ToString
End While
dr.Close()
cn.Close()
End Sub
28
Private Sub ListBox1_Click(sender As Object, e As EventArgs)
Handles ListBox1.Click
TextBox1.Text =
ListBox1.SelectedItem.ToString dummy = TextBox1.Text
Dim sql As String = "SELECT ROW_NUMBER() OVER (ORDER BY
Groupname,Cost,Remarks) Sno,Groupname,Cost,Remarks FROM TestGroup where Groupname='"&
dummy &"'"
29
Imports System.Data
Imports System.Math
Imports System.Drawing
Imports System.IO
Imports System.Reflection
TextBox1.Focus()
KeyPreview = True
autosno()
Panel2.Enabled = False
Gvset()
Catch ex As Exception
End Try
con.Close()
connection.Close()
End Sub
clear()
autosno()
Panel2.Enabled = False
Else
Dim cmd As SqlCommand
If con.State<>ConnectionState.Open Then con.Open()
cmd = New SqlCommand("Update Company Set Cname='"& TextBox1.Text &"',Address='"&
TextBox2.Text &"',City='"& TextBox3.Text &"',Contact='"& TextBox4.Text &"',Email='"&
TextBox5.Text &"',Fyear1='"& TextBox6.Text &"',Fyear2='"& TextBox7.Text &"',Uname='"&
TextBox8.Text &"',Pword='"& TextBox9.Text &"' Where Cid='"& TextBox10.Text &"'", con)
cmd.ExecuteNonQuery()
clear()
autosno()
Panel2.Enabled = False End If
End Sub
Sub clear()
TextBox1.Text = ""
30
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox6.Text = ""
TextBox7.Text = ""
TextBox8.Text = ""
TextBox9.Text = ""
TextBox10.Text = ""
TextBox1.Focus()
End Sub
Dim no
Sub autosno()
End If
dr1.Close()
con.Close()
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
autosno()
Panel2.Enabled = True
End Sub
Dim dummy
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
Dim cmd3 As SqlCommand
Dim dr3 As SqlDataReader
Dim T
dummy = DataGridView1.CurrentCell.Value.ToString()
cmd3 = New SqlCommand("SELECT * FROM Company where Cid='"& dummy &"'", con1)
dr3 = cmd3.ExecuteReader
While dr3.Read
TextBox10.Text = dr3(0).ToString
TextBox1.Text = dr3(1).ToString
31
TextBox2.Text = dr3(2).ToString
TextBox3.Text = dr3(3).ToString
TextBox4.Text = dr3(4).ToString
TextBox5.Text = dr3(5).ToString
TextBox6.Text = dr3(6).ToString
TextBox7.Text = dr3(7).ToString
TextBox8.Text = dr3(8).ToString
TextBox9.Text = dr3(9).ToString
End While
dr3.Close()
con1.Close() connection.Close()
End Sub
Sub Gvset()
DataGridView1.Rows.Clear()
DataGridView1.Columns.Clear()
DataGridView1.Columns.Add("ColSNo", "C.ID")
DataGridView1.Columns.Add("ColSNo", "Company Name")
DataGridView1.Columns.Add("ColSNo", "From")
DataGridView1.Columns.Add("ColSNo", "To")
DataGridView1.Columns(0).Width = 50
DataGridView1.Columns(1).Width = 250
DataGridView1.Columns(2).Width = 75
DataGridView1.Columns(3).Width = 75
DataGridView1.Columns(0).DefaultCellStyle.Alignment =
DataGridViewContentAlignment.MiddleCenter
DataGridView1.Columns(1).DefaultCellStyle.Alignment =
DataGridViewContentAlignment.MiddleCenter
DataGridView1.Columns(2).DefaultCellStyle.Alignment =
DataGridViewContentAlignment.MiddleCenter
DataGridView1.Columns(3).DefaultCellStyle.Alignment =
DataGridViewContentAlignment.MiddleCenter
DataGridView1.Columns(0).ReadOnly = True
DataGridView1.Columns(1).ReadOnly = True
DataGridView1.Columns(2).ReadOnly = True
DataGridView1.Columns(3).ReadOnly = True
DataGridView1.Columns(0).DefaultCellStyle.Font = New Font("Times New Roman", 10.0F,
FontStyle.Bold)
DataGridView1.Columns(1).DefaultCellStyle.Font = New Font("Times New Roman", 10.0F,
FontStyle.Bold)
DataGridView1.Columns(2).DefaultCellStyle.Font = New Font("Times New Roman", 10.0F,
FontStyle.Bold)
DataGridView1.Columns(3).DefaultCellStyle.Font = New Font("Times New Roman", 10.0F,
FontStyle.Bold)
'DataGridView1.Columns(0).DefaultCellStyle.ForeColor = Color.AliceBlue
'DataGridView1.Columns(1).DefaultCellStyle.ForeColor = Color.AliceBlue
'DataGridView1.Columns(2).DefaultCellStyle.ForeColor = Color.AliceBlue
'DataGridView1.Columns(3).DefaultCellStyle.ForeColor = Color.AliceBlue
DataGridView1.Columns(0).HeaderText = "C.ID"
DataGridView1.Columns(1).HeaderText = "Company Name"
DataGridView1.Columns(2).HeaderText = "From"
DataGridView1.Columns(3).HeaderText = "To"
Dim cmd3 As SqlCommand
Dim dr3 As SqlDataReader
If con.State<>ConnectionState.Open Then con.Open()
cmd3 = New SqlCommand("Select Cid,Cname,Fyear1,Fyear2 from Company",
con) dr3 = cmd3.ExecuteReader
32
Dim iAs Integer = 0
While dr3.Read
DataGridView1.Rows.Add()
DataGridView1.Rows(i).Cells(0).Value = dr3(0).ToString
DataGridView1.Rows(i).Cells(1).Value = dr3(1).ToString
DataGridView1.Rows(i).Cells(2).Value = dr3(2).ToString
DataGridView1.Rows(i).Cells(3).Value = dr3(3).ToString
i = i + 1
End While
dr3.Close()
con.Close()
End Sub Private Sub DataGridView1_Click(sender As Object, e As EventArgs)
Handles DataGridView1.Click
Dim cmd3 As SqlCommand
Dim dr3 As SqlDataReader
Dim T
If con1.State <>ConnectionState.Open Then con1.Open()
dummy = DataGridView1.CurrentCell.Value.ToString()
cmd3 = New SqlCommand("SELECT Cid FROM Company where Cid='"& dummy &"'", con1)
dr3 = cmd3.ExecuteReader
While dr3.Read
T = dr3(0).ToString
End While
dr3.Close()End Class
33
D. SAMPLE INPUT
HOME PAGE
34
ADMIN LOGIN
35
ADMIN HOME
36
QUIZ DETAILS
37
REMOVE QUIZ
38
USER REGISTRATION
39
USER LOGIN
40
EXAM TITLE
41
QUESTION-1
42
QUESTION-2
43
QUESTION-3
44
RESULT
45
HISTORY
46
E. SAMPLE OUTPUT
RANK REPORT
47
USER REORT
48