Vous êtes sur la page 1sur 50

CAREER PLANNER

1


CHAPTER-1
INTRODUCTION TO C# & .NET

1.1 Object-Oriented Programming
Object-oriented programming (OOP) introduced the concept of classes and objects in the
early 90s. This methodology is based on the scientific classification principles of ordering
and naming groups within subject fields. For example, the Mankind class represents all
humans. This class possesses characteristics, such as the body parts and senses, and exercises
a behavior, such as the ability to speak. From this class come the Man class and the Woman
class. Each of these classes inherits the characteristics and behavior from the Mankind class
and adds to its specific characteristics of the Man or the Woman. The Man class is actually an
abstraction of the behavior and characteristics of a Man, from which you can create instances
or objects such as Craig and Dylan. From the Woman you create objects such as Isabella and
Angelina.
In programming, you divide your data into classes. You can, for example, represent the
elevators by the class Elevator, which contains the data fields that represent the
characteristics (the elevator number, the number of floors, and the floor number), and the
methods (or functions) that represent the behavior (going up or down). From the Elevator
class, you can create objects such as elevator1, elevator2, and so forth. In fact, you dont have
to write the Elevator class yourself in order to use it. It might be created by another
programmer or another company, and you just use it in your code, without even seeing the
source code.
The OOP principles are summarized in the following list:
Abstraction: The ability to create abstract data objects (classes) that can be used to
create instances.
Encapsulation: Protecting some data members by hiding the implementation and
exposing the interface.
CAREER PLANNER

2

Inheritance: Reusing the code by specializing classes and adding features to them.
Polymorphism: Changing the behavior of the methods of the inherited class.

1.2 C#: The OOP Language
Although the C++ language is object oriented, it is in fact a mixture of both methodologies,
the traditional and OOP approaches. This means that you can create an object-oriented
program consisting of objects that contain the fields and the methods together, or you can
write the same old code with global variables scattered in the program file and exposed to
accidental changes by other programmers. With small applications, it might be okay to use
the traditional method, but with complex programs that are shared by a large number of
programmers, the need for OOP arises. C# was built from the ground up as an OOP language.
That means you cannot create a program without building your classes first and having the
fields and methods (the class members) inside their classes. C# was an evolution of C++, and
solved a lot of issues that have always faced C++ programmers. For example, it got rid of
pointers that wasted programmers time and effort in resolving associated problems such as
memory leaks. It also got rid of multiple class inheritance, which caused more problems than
benefits. In addition, the generics feature that came with C# 2005 was useful and easier to use
than C++ templates.
1.3 .NET Class Library:-
The .NET class library is a giant repository of classes that provide prefabricated functionality
for everything from reading an XML file to sending an e-mail message. If youve had any
exposure to Java, However, the .NET class library is more ambitious and comprehensive than
just about any other programming framework. Any .NET language can use the .NET class
librarys features by interacting with the right objects. This helps encourage consistency
among different .NET languages and removes the need to install numerous components on
your computer or web server.
Some parts of the class library include features youll never need to use in web applications
(such as the classes used to create desktop applications with Windows interfaces). Other parts
of the class library are targeted directly at web development. Still more classes can be used in
various programming scenarios and arent specific to web or Windows development. These
CAREER PLANNER

3

include the base set of classes that define common variable types and the classes for data
access, to name just a few.
Microsofts philosophy is that it will provide the tedious infrastructure so that application
developers need only to write business specific code. For example, the .NET Framework
deals with thorny issues such as database transactions and concurrency, making sure that
hundreds or thousands of simultaneous users can request the same web page at once. You just
add the logic needed for your specific application.
1.4 Microsoft .NET Framework:-
The .NET Framework is the infrastructure for the Microsoft .NET platform. The .NET
Framework is an environment for building, deploying, and running Web applications and
Web Services. Microsoft's first server technology ASP (Active Server Pages), was a powerful
and flexible "programming language". But it was too code oriented. It was not an application
framework and not an enterprise development tool. The Microsoft .NET Framework was
developed to solve this problem.
.NET Frameworks keywords:
Easier and quicker programming
Reduced amount of code
Declarative programming model
Larger class library
Richer server control hierarchy with events
Better support for development tool
The .NET Framework consists of 3 main parts:
Programming languages:
a. C# (Pronounced C sharp).
b. Visual Basic (VB .NET).
Server technologies and client technologies:
a. ASP .NET (Active Server Pages)
b. Windows Forms (Windows desktop solutions).
CAREER PLANNER

4

Development environments:
a. Visual Studio .NET (VS .NET)
b. Visual Web Developer
1.4.1 Intermediate Language
All the .NET languages are compiled into another lower-level language before the code is
executed. This lower-level language is the Common Intermediate Language (CIL, or just IL).
The CLR, the engine of .NET, uses only IL code. Because all .NET languages are designed
based on IL, they all have profound similarities. This is the reason that the VB and C#
languages provide essentially the same features and performance. In fact, the languages are
so compatible that a web page written with C# can use a VB component in the same way it
uses a C# component, and vice versa. The .NET Framework formalizes this compatibility
with something called the Common Language Specification (CLS). Essentially, the CLS is a
contract that, if respected, guarantees that a component written in one .NET language can be
used in all the others. One part of the CLS is the common type system (CTS), which defines
the rules for data types such as strings, numbers, and arrays that are shared in all .NET
languages. The CLS also defines object-oriented ingredients such as classes, methods, events,
and quite a bit more. For the most part, .NET developers dont need to think about how the
CLS works, even though they rely on it every day.
1.4.2 Common Language Runtime:-

The Common Language Runtime is the engine that compiles the source code in to an
intermediate language. This intermediate language is called the Microsoft Intermediate
Language. During the execution of the program this MSIL is converted to the native code or
the machine code. This conversion is possible through the Just-In-Time compiler.
The Common Language Specification (CLS) and the Common Type System (CTS),
fundamental parts of the CLR, define the types and syntax that can be used with many .NET
languages. The CTS is a standard that defines how CLR represents and manages types. The
CLS is a subset of the features that programming languages must support in order to execute
in the context of CLR. During compilation the end result is a Portable Executable file (PE).
This portable executable file contains the MSIL and additional information called the
metadata. This metadata describes the assembly that is created. Class names, methods,
signature and other dependency information are available in the metadata. Since the CLR
CAREER PLANNER

5

compiles the source code to an intermediate language, it is possible to write the code in any
language of your choice. This is a major advantage of using the .Net framework.
The other advantage is that the programmers need not worry about managing the memory
themselves in the code. Instead the CLR will take care of that through a process called
Garbage collection. This frees the programmer to concentrate on the logic of the application
instead of worrying about memory handling. The role of CLR does not end after compiling
the IL code into native code. In fact, the CLR is responsible for managing memory during the
code execution. It assures that the memory used by the program is totally freed up after the
program exits. With unmanaged applications, programmers are responsible for managing the
memory and resolving problems that might occur if a block of memory is left allocated after
the program ends.

1.4.3 Flow Chart of CLR Execution Model:-


Fig: 1.1 Flow Chart of CLR Execution Model
CLR comes as part of .Net framework. This is a run time that is useable by different and
varied programming language. All .NET code runs inside the CLR. This is true whether
CAREER PLANNER

6

youre running a Windows application or a web service. For example, when a client requests
an ASP.NET web page, the ASP.NET service runs inside the CLR environment, executes
your code, and creates a final HTML page to send to the client. The implications of the CLR
are wide-ranging:
Deep language integration: VB and C#, like all .NET languages, compile to IL. In
other of knowing what language was used to create an executable? This is far more
than mere language compatibility; its language integration.
Side-by-side execution: The CLR also has the ability to load more than one version of
a component at a time. In other words, you can update a component many times, and
the correct version will be loaded and used for each application. As a side effect,
multiple versions of the .NET Framework can be installed, meaning that youre able
to upgrade to new versions of ASP.NET without replacing the current version or
needing to rewrite your applications.
Fewer errors: Whole categories of errors are impossible with the CLR. For example,
the CLR prevents many memory mistakes that are possible with lower-level
languages such as C++. Along with these truly revolutionary benefits, the CLR has
some potential drawbacks. Here are three issues that are often raised by new
developers but arent always answered:
Performance: A typical ASP.NET application is much faster than a comparable ASP
application, because ASP.NET code is compiled to machine code before its executed.
However, processor crunching algorithms still cant match the blinding speed of well-
written C++ code, because the CLR imposes some additional overhead. Generally,
this is a factor only in a few performance-critical high-workload applications.
Code transparency: IL is much easier to disassemble, meaning that if you distribute a
compiled application or component, other programmers may have an easier time
determining how your code works. This isnt much of an issue for ASP.NET
applications, which arent distributed but are hosted on a secure web server.
Questionable cross-platform support: Thanks to the Mono project, developers can use
a free implementation of .NET that runs on Linux, UNIX, Mac OS, and Windows.
However, Mono is supported by the open source community, not Microsoft, and it
doesnt provide all of .NETs features. For this reason, few businesses use Mono
instead of .NET.
CAREER PLANNER

7

Features of CLR are as follows:-
Memory Management
Assembly Loading
Security
Exception Handling
Thread Synchronization
Any language which targets its compiled output to CLR can avail above features.
1.4.4 Managed Module:-
This is either 32 bit or 64 bit Microsoft Standard Portable Executable File Format. These are
the files required by CLR to execute. Compiler of all high level language does the task of
syntax checking and language analysis and targets the compiled output to CLR. All languages
outputs PE 32 or PE32+ format files and that will get executed by CLR to produce CPU
instructions
.

Fig: 1.2 Managed Modules

CHAPTER 2
DBMS & SQL
CAREER PLANNER

8

2.1 Database:-
A database as a self-describing collection of integrated records that does imply computer
technology, complete with languages such as SQL.A database is a collection of Data
(Information). Examples of databases, which we use in our daily life, are an Attendance
Register, Telephone Directory, and Muster Rule.
A record is a representation of some physical or conceptual object. For example, that we
want to keep track of a businesss customers. We assign a record for each customer. Each
record has multiple attributes, such as name, address, and telephone number. Individual
names, addresses, and so on are the data.
A database consists of both data and metadata. Metadata is the data that describes the datas
structure within a database. If you know how your data is arranged, then we can retrieve it.
Because the database contains a description of its own structure, its self-describing. The
database is integrated because it includes not only data items but also the relationships among
data items.
The database stores metadata in an area called the data dictionary, which describes the tables,
columns, indexes, constraints, and other items that make up the database. Because a flat file
system has no metadata, applications written to work with flat files must contain the
equivalent of the metadata as part of the application program.

2.2 Database Management System (DBMS):

A Database Management System (DBMS) is a software package with computer programs
that control the creation, maintenance, and the use of a database. It allows organizations to
conveniently develop databases for various applications by database administrators (DBAs)
and other specialists. A database is an integrated collection of data records, files, and other
database objects. A DBMS allows different user application programs to concurrently access
the same database. DBMSs may use a variety of database models, such as the relational
model or object model, to conveniently describe and support applications. It typically
supports query languages, which are in fact high-level programming languages, dedicated
database languages that considerably simplify writing database application programs.
Database languages also simplify the database organization as well as retrieving and
CAREER PLANNER

9

presenting information from it. A DBMS provides facilities for controlling data access,
enforcing data integrity, managing concurrency
A database management system is a collection of programs written to manage a database.
That is, it acts as an interface between user and database.

Fig: 2.1 Database Management System

2.3 RDBMS (Relational Database Management System):-

A relational database management system (RDBMS) is a database management system
(DBMS) that is based on the relational model as introduced by E. F. Codd. Most popular
commercial and open source databases currently in use are based on the relational database
model.
A short definition of an RDBMS is: a DBMS in which data is stored in tables and the
relationships among the data are also stored in tables. The data can be accessed or
reassembled in many different ways without having to change the table forms.

2.4 Sql Server:-
Microsoft SQL Server is a relational database server product by Microsoft. Its primary query
languages are T-SQL and ANSI SQL. Microsoft SQL Server is an application used to create
computer databases for the Microsoft Windows family of server operating systems. Microsoft
SQL Server provides an environment used to generate databases that can be accessed from
workstations, the Internet, or other media such as a personal digital assistant (PDA). MSSQL
is an Object-Relational Database Management System. It is the leading RDBMS vendor
worldwide. Nearly half of RDBMS worldwide market is owned by MSSQL.
CAREER PLANNER

10

SQL SERVER is a relational database management system: A relational database stores data
in separate tables rather than putting all the data in one big storeroom. This adds speed and
flexibility. The tables are linked by defined relations making it possible to combine data from
several tables on request. The SQL part stands for "Structured Query Language" -the most
common standardized language used to access databases.

2.5 Data types and Creating Tables:
A table is the data structure that holds data in a relational database. A table is composed of
rows and columns.
Fig: 2.2 Data types and Creating Tables

A table in MSSQL Ver. 7.3 can have maximum 255 Columns and in MSSQL Ver. 8 and
above a table can have maximum 1000 columns. Number of rows in a table is unlimited in all
the versions. A table can represent a single entity that you want to track within your system.
This type of a table could represent a list of the employees within your organization, or the
orders placed for your company's products. A table can also represent a relationship between
two entities. This type of a table could portray the association between employees and their
job skills, or the relationship of products to orders. Within the tables, foreign keys are used to
represent relationships. Although some well-designed tables could represent both an entity
and describe the relationship between that entity and another entity, most tables should
represent either an entity or a relationship.
The following sessions explain how to create, alter, and drop tables. Some simple guidelines
to follow when managing tables in your database are included.

2.5.1 Designing Tables:
CAREER PLANNER

11

Consider the following guidelines when designing your tables:
Use descriptive names for tables, columns, indexes, and clusters.
Be consistent in abbreviations and in the use of singular and plural forms of table
names and columns.
Document the meaning of each table and its columns with the COMMENT command.
Normalize each table.
Select the appropriate data type for each column.
Define columns that allow nulls last, to conserve storage space.
Cluster tables whenever appropriate, to conserve storage space and optimize
performance of SQL statements.
Before creating a table, you should also determine whether to use integrity constraints.
Integrity constraints can be defined on the columns of a table to enforce the business rules of
your database automatically.
Before creating a Table you have to decide what type of data each column can contain. This
is known as data type. Lets discuss what data types are available in MSSQL.
2.5.2 Data types:
A data type associates a fixed set of properties with the values that can be used in a column of
a table or in an argument of a procedure or function. These properties cause MSSQL to treat
values of one data type differently from values of another data type. For example, MSSQL
can add values of NUMBER data type, but not values of RAW data type.
MSSQL supplies the following built-in data types:
Character data types
a. CHAR
b. NCHAR
c. VARCHAR2 and VARCHAR
d. NVARCHAR2
e. CLOB
f. NCLOB
g. LONG
Time and date data types:
CAREER PLANNER

12

a. DATA
b. INTERVAL DAY TO SECOND
c. INTERVAL YEAR TO MONTH
d. TIMESTAMP
e. TIMESTAMP WITH TIME ZONE
f. TIMESTAMP WITH LOCAL TIME ZONE
Binary data types
a. BLOB
b. BFILE
c. RAW
d. LONG RAW
Another data type, ROWID, is used for values in the ROWID pseudo column, which
represents the unique address of each row in a table.
The following table summarizes the information about each MSSQL built-in data type.

CAREER PLANNER

13

Data
Type
Description Column Length and Default
CHAR (size
[BYTE | CHAR])
Fixed-length
character data of
length size bytes or
characters.
Fixed for every row in the table (with
trailing blanks); maximum size is 2000
bytes per row, default size is 1 byte per row.
Consider the character set (single-byte or
multibyte) before setting size.
VARCHAR2
(size [BYTE |
CHAR])
Variable-length
character data, with
maximum length
size bytes or
characters.
Variable for each row, up to 4000 bytes per
row. Consider the character set (single-byte
or multibyte) before setting size. A
maximum size must be specified.
NCHAR (size)
Fixed-length
Unicode character
data of length size
characters.
Variable for each row. Column size is the
number of characters. (The number of bytes
may be up to 2 times this number for an
AL16UTF16 encoding and 3 times this
number for the UTF8 encoding.) The upper
limit is 4000 bytes per row. Default is 1
character.
NVARCHAR2
(size)
Variable-length
Unicode character
data of length size
characters.
Up to 2
32
- 1 bytes, or 4 gigabytes.
CLOB
Single-byte
character data
Up to 2
32
- 1 bytes, or 4 gigabytes.
NCLOB
Unicode national
character set (NCHAR)
data.
Variable for each row in the table, up to
2
32
- 1 bytes, or 2 gigabytes, per row.
Provided for backward compatibility.
LONG
Variable-length
character data.
Variable for each row. The maximum space
required for a given column is 21 bytes per
row.
CAREER PLANNER

14

NUMBER (p, s)
Variable-length
numeric data.
Maximum precision
p and/or scale s is
38.
Fixed at 7 bytes for each row in the table.
Default format is a string (such as DD-
MON-RR) specified by the
NLS_DATE_FORMAT parameter.
DATE
Fixed-length date
and time data,
ranging from Jan. 1,
4712 B.C.E. to Dec.
31, 4712 C.E.
Fixed at 5 bytes.
INTERVAL
YEAR
(precision) TO
MONTH
A period of time,
represented as years
and months. The
precision value
specifies the number
of digits in the
YEAR field of the
date. The precision
can be from 0 to 9,
and defaults to 2 for
years.
Fixed at 11 bytes.
INTERVAL
DAY (precision)
TO SECOND
(precision)

The precision
values specify the
number of digits in
the DAY and the
fractional SECOND
fields of the date.
Fixed at 13 bytes. The default is determined
by the NLS_TIMESTAMP_TZ_FORMAT
initialization parameter.
TIMESTAMP
(precision) WITH
TIME ZONE
A value
representing a date
and time, plus an
associated time zone
setting which can be
Varies from 7 to 11 bytes, depending on the
precision. The default is determined by the
NLS_TIMESTAMP_FORMAT
initialization parameter.
CAREER PLANNER

15

Table: 2.1 MSSQL built-in data type
an offset from UTC,
such as '-5:0', or a
region name, such
as 'US/Pacific'.
TIMESTAMP
(precision) WITH
LOCAL TIME
ZONE
Similar to
TIMESTAMP
WITH TIME
ZONE, except that
the data is
normalized to the
database time zone
when stored, and
adjusted to match
the client's time
zone when
retrieved.
Up to 2
32
- 1 bytes, or 4 gigabytes.
BLOB
Unstructured binary
data
Variable for each row in the table, up to
2000 bytes per row. A maximum size must
be specified. Provided for back ward
compatibility.
RAW (size)
Variable-length raw
binary data
Variable for each row in the table, up to
2
31
- 1 bytes, or 2 gigabytes, per row.
Provided for backward compatibility.
LONG
RAW
Variable-length raw
binary data
Fixed at 10 bytes (extended ROWID) or 6
bytes (restricted ROWID) for each row in
the table.
ROWID
Binary data
representing row
addresses

CAREER PLANNER

16

CHAPTER3
OVERVIEW of ASP.NET
3.1 Introduction:-
ASP.NET is a web application framework developed and marketed by Microsoft to allow
programmers to build dynamic web sites, web applications and web services. It was first
released in January 2002 with version 1.0 of the .NET Framework, and is the successor to
Microsoft's Active Server Pages (ASP) technology. ASP.NET is built on the Common
Language Runtime (CLR), allowing programmers to write ASP.NET code using any
supported .NET language. The ASP.NET SOAP extension framework allows ASP.NET
components to process SOAP messages.
ASP.NET is a server side scripting technology that enables scripts (embedded in web
pages) to be executed by an Internet server.
ASP.NET is a Microsoft Technology
ASP stands for Active Server Pages
ASP.NET is a program that runs inside IIS
IIS (Internet Information Services) is Microsoft's Internet server
IIS comes as a free component with Windows servers
IIS is also a part of Windows 2000 and XP Professional
3.2 Characteristics:-
3.2.1Pages
ASP.NET web pages or webpage, known officially as Web Forms, are the main building
block for application development. Web forms are contained in files with an ".aspx"
extension; these files typically contain static (X) HTML markup, as well as markup defining
server-side Web Controls and User Controls where the developers place all the required static
and dynamic content for the web page. Additionally, dynamic code which runs on the server
can be placed in a page within a block <% -- dynamic code -- %>, which is similar to other
web development technologies such as PHP, JSP, and ASP. With ASP.NET Framework 2.0,
Microsoft introduced a new code-behind model which allows static text to remain on the
.aspx page, while dynamic code remains in an .aspx.vb or .aspx.cs or .aspx.fs file (depending
on the programming language used).
CAREER PLANNER

17

3.2.2 Code-behind model:
Microsoft recommends dealing with dynamic program code by using the code-behind model,
which places this code in a separate file or in a specially designated script tag. Code-behind
files typically have names like MyPage.aspx.cs or MyPage.aspx.vb while the page file is
MyPage.aspx (same filename as the page file (ASPX), but with the final extension denoting
the page language). This practice is automatic in Microsoft Visual Studio and other IDEs.
When using this style of programming, the developer writes code to respond to different
events, like the page being loaded, or a control being clicked, rather than a procedural
walkthrough of the document ASP.NET's code-behind model marks a departure from Classic
ASP in that it encourages developers to build applications with separation of presentation and
content in mind. In theory, this would allow a web designer, for example, to focus on the
design markup with less potential for disturbing the programming code that drives it. This is
similar to the separation of the controller from the view in ModelViewController (MVC)
frameworks.
3.2.3 Directives
A directive is special instructions on how ASP.NET should process the page. The most
common directive is <%@ Page %> which can specify many things, such as which
programming language is used for the server-side code
3.3 User Controls
User controls are encapsulations of sections of pages which are registered and used as
controls in ASP.NET. User controls are created as ASCX markup files. These files usually
contain static (X) HTML markup, as well as markup defining server-side web controls. These
are the locations where the developer can place the required static and dynamic content. A
user control is compiled when its containing page is requested and is stored in memory for
subsequent requests. User controls have their own events which are handled during the life of
ASP.NET requests. An event bubbling mechanism provides the ability to pass an event fired
by a user control up to its containing page. Unlike an ASP.NET page, a user control cannot
be requested independently; one of its containing pages is requested instead.
3.4 Custom Controls
CAREER PLANNER

18

Programmers can also build custom controls for ASP.NET applications. Unlike user controls,
these controls do not have an ASCX markup file, having all their code compiled into a
dynamic link library (DLL) file. Such custom controls can be used across multiple web
applications and Visual Studio projects.
3.5 Rendering Technique
ASP.NET uses a visited composites rendering technique. During compilation, the template
(.aspx) file is compiled into initialization code which builds a control tree (the composite)
representing the original template. Literal text goes into instances of the Literal control class,
and server controls are represented by instances of a specific control class. The initialization
code is combined with user-written code (usually by the assembly of multiple partial classes)
and results in a class specific for the page. The page doubles as the root of the control tree.
Actual requests for the page are processed through a number of steps. First, during the
initialization steps, an instance of the page class is created and the initialization code is
executed. This produces the initial control tree which is now typically manipulated by the
methods of the page in the following steps. As each node in the tree is a control represented
as an instance of a class, the code may change the tree structure as well as manipulate the
properties/methods of the individual nodes. Finally, during the rendering step a visitor is used
to visit every node in the tree, asking each node to render itself using the methods of the
visitor. The resulting HTML output is sent to the client. After the request has been processed,
the instance of the page class is discarded and with it the entire control tree. This is a source
of confusion among novice ASP.NET programmers who rely on class instance members that
are lost with every page request/response cycle.
3.6 State Management
ASP.NET applications are hosted by a web server and are accessed using the stateless HTTP
protocol. As such, if an application uses stateful interaction, it has to implement state
management on its own. ASP.NET provides various functions for state management.
Conceptually, Microsoft treats "state" as GUI state. Problems may arise if an application
needs to keep track of "data state"; for example, a finite state machine which may be in a
transient state between requests (lazy evaluation) or which takes a long time to initialize.
State management in ASP.NET pages with authentication can make Web scraping difficult or
impossible.
CAREER PLANNER

19

3.7 Application State
Application state is held by a collection of shared user-defined variables. These are set and
initialized when the Application On Start event fires on the loading of the first instance of the
application and are available until the last instance exits. Application state variables are
accessed using the Applications collection, which provides a wrapper for the application
state. Application state variables are identified by name.
3.8 Session State
Server-side session state is held by a collection of user-defined session variables that are
persistent during a user session. These variables, accessed using the Session collection, are
unique to each session instance. The variables can be set to be automatically destroyed after a
defined time of inactivity even if the session does not end. Client-side user session is
maintained by either a cookie or by encoding the session ID in the URL itself.ASP.NET
supports three modes of persistence for server-side session variables:
3.8.1 In-Process Mode
The session variables are maintained within the ASP.NET process. This is the fastest way;
however, in this mode the variables are destroyed when the ASP.NET process is recycled or
shut down.
3.8.2 ASP State Mode
ASP.NET runs a separate Windows service that maintains the state variables. Because state
management happens outside the ASP.NET process, and because the ASP.NET engine
accesses data using .NET Remoting, ASP State is slower than In-Process. This mode allows
an ASP.NET application to be load-balanced and scaled across multiple servers. Because the
state management service runs independently of ASP.NET, the session variables can persist
across ASP.NET process shutdowns. However, since session state server runs as one
instance, it is still one point of failure for session state. The session-state service cannot be
load-balanced, and there are restrictions on types that can be stored in a session variable.
3.8.3 Sql Server Mode
State variables are stored in a database, allowing session variables to be persisted across
ASP.NET process shutdowns. The main advantage of this mode is that it allows the
CAREER PLANNER

20

application to balance load on a server cluster, sharing sessions between servers. This is the
slowest method of session state management in ASP.NET.
3.9 View State:
View state refers to the page-level state management mechanism, utilized by the HTML
pages emitted by ASP.NET applications to maintain the state of the web form controls and
widgets. The state of the controls is encoded and sent to the server at every form submission
in a hidden field known as __VIEWSTATE. The server sends back the variable so that when
the page is re-rendered, the controls render at their last state. At the server side, the
application may change the view state, if the processing requires a change of state of any
control. The states of individual controls are decoded at the server, and are available for use
in ASP.NET pages using the View State collection.
The main use for this is to preserve form information across post backs. View state is turned
on by default and normally serializes the data in every control on the page regardless of
whether it is actually used during a post back. This behavior can (and should) be modified,
however, as View state can be disabled on a per-control, per-page, or server-wide basis.
Developers need to be wary of storing sensitive or private information in the View state of a
page or control, as the base64 string containing the view state data can easily be de-serialized.
By default, View state does not encrypt the __VIEWSTATE value. Encryption can be
enabled on a server-wide (and server-specific) basis, allowing for a certain level of security to
be maintained.
3.10 Other
Other means of state management that are supported by ASP.NET are cookies, caching, and
using the query string.
3.11 Server-Side Caching
ASP.NET offers a "Cache" object that is shared across the application and can also be used to
store various objects. The "Cache" object holds the data only for a specified amount of time
and is automatically cleaned after the session time-limit elapses.
3.12 Template Engine
CAREER PLANNER

21

When first released, ASP.NET lacked a template engine. Because the .NET Framework is
object-oriented and allows for inheritance, many developers would define a new base class
that inherits from "System.Web.UI.Page", write methods there that render HTML, and then
make the pages in their application inherit from this new class. While this allows for common
elements to be reused across a site, it adds complexity and mixes source code with markup.
Furthermore, this method can only be visually tested by running the application - not while
designing it.
ASP.NET 2.0 introduced the concept of "master pages", which allow for template-based page
development. A web application can have one or more master pages, which, beginning with
ASP.NET 2.0, can be nested. Master templates have place-holder controls, called
ContentPlaceHolders to denote where the dynamic content goes, as well as HTML and
JavaScript shared across child pages. Child pages use those ContentPlaceHolder controls,
which must be mapped to the place-holder of the master page that the content page is
populating. The rest of the page is defined by the shared parts of the master page, much like a
mail merge in a word processor. All markup and server controls in the content page must be
placed within the ContentPlaceHolder control.
When a request is made for a content page, ASP.NET merges the output of the content page
with the output of the master page, and sends the output to the user.
The master page remains fully accessible to the content page. This means that the content
page may still manipulate headers, change title, configure caching etc. If the master page
exposes public properties or methods (e.g. for setting copyright notices) the content page can
use these as well.

3.13 Directory Structure
In general, the ASP.NET directory structure can be determined by the developer's
preferences. Apart from a few reserved directory names, the site can span any number of
directories. The structure is typically reflected directly in the URLs. Although ASP.NET
provides means for intercepting the request at any point during processing, the developer is
not forced to funnel requests through a central application or front controller.
The special directory names (from ASP.NET 2.0 on) are:
CAREER PLANNER

22

3.13.1 App_Code
This is the "raw code" directory. The ASP.NET server automatically compiles files (and
subdirectories) in this folder into an assembly which is accessible in the code of every page of
the site. App_Code will typically be used for data access abstraction code, model code and
business code. Also any site-specific http handlers and modules and web service
implementation go in this directory. As an alternative to using App_Code the developer may
opt to provide a separate assembly with precompiled code.
3.13.2 App_Data
Default directory for databases, such as Access mdb files and SQL Server mdf files. This
directory is usually the only one with write access for the application.
3.13.3 App_Local Resources
E.g. a file called CheckOut.aspx.fr-FR.resx holds localized resources for the French version
of the CheckOut.aspx page. When the UI culture is set to French, ASP.NET will
automatically find and use this file for localization.
3.13.4 App_Global Resources
Holds resx files with localized resources available to every page of the site. This is where the
ASP.NET developer will typically store localized messages etc. which are used on more than
one page.

3.13.5 App_Themes
Adds a folder that holds files related to themes which are a new ASP.NET feature that helps
ensure a consistent appearance throughout a Web site and makes it easier to change the Web
sites appearance when necessary.
3.13.6 Bin
Contains compiled code (.dll files) for controls, components, or other code that you want to
reference in your application. Any classes represented by code in the Bin folder are
automatically referenced in your application.
CAREER PLANNER

23

3.14 Performance
ASP.NET aims for performance benefits over other script-based technologies (including
Classic ASP) by compiling the server-side code to one or more DLL files on the web server.
This compilation happens automatically the first time a page is requested. The ASPX and
other resource files are placed in a virtual host on an Internet Information Services server (or
other compatible ASP.NET servers). The first time a client requests a page, the .NET
Framework parses and compiles the file(s) into a .NET assembly and sends the response;
subsequent requests are served from the DLL files. By default ASP.NET will compile the
entire site in batches of 1000 files upon first request. If the compilation delay is causing
problems, the batch size or the compilation strategy may be tweaked.
3.15 Extension
Microsoft has released some extension frameworks that plug into ASP.NET and extend its
functionality. Some of them are:
3.15.1 ASP.NET AJAX
An extension with both client-sides as well as server-side components for writing ASP.NET
pages that incorporate AJAX functionality.
CAREER PLANNER

24

CHAPTER 4
CAREER PLANNER
4.1 Introduction:-
Career is the sequence and variety of occupations (paid and unpaid) which one undertakes
throughout a lifetime. It is generally observed that a large section of students are unaware of
what they want to achieve in life. This amounts to a situation like boarding a train without
knowing ones destination. It may result in waste of precious time as well as money thats
why we created this portal Career Planner.
Career Planner is the web portal name. With IT evolution as its peak, this task should also
be converted into a computerized process and keeping this in mind we thought of buildings
this web portal which reduces the time, energy and efforts for systematic processing of data.
These days Internet is a very popular mode of communication because most of the people are
computer literate.
The proposed solution is a web portal through which users can access the career option and
their details which they want to opt for .This system provide the information about the
colleges in Jaipur regarding different fields, conduct online exam for self evaluation. The
system will be a database driven web-based solution that can provide easy and faster access
and posting of information related to courses, virtual classroom, and information on colleges
according to users requirements. The portal will be dynamic with a backend Admin Control
panel and will allow portal administrator to manage portal content including management of
users, tests, uploading and downloading of data etc. Registered Users of this solution will be
able to conduct exam, upload and download data according to their requirement.
Non registered users can access the portal, become a member of the portal through creating
their account, can gain information about the colleges and the courses offered in respective
institutions.

There are two system actors client and the server. The client part in this portal would be the
.NET framework because it is the framework which we are going to use in developing this
project. We are developing a web application which will work offline as well as online so the
server parts in this portal will be IIS.
CAREER PLANNER

25

4.2 Specific Objective of the Portal
To think act big is indispensable to rise rapidly in our career
Success in our career in new millennium necessitates firm commitment, vision,
managerial ability to solve problem at our place of work and continuous up gradation
of professional sill in examination result & hard work.
Whatever be our choice, it is necessary to identify & explore the opportunities that are
available.
To innovate & create opportunities for our career enhancement is also necessary with
regards to selection of career; it is classified that career included here may not be the
last word on being top ten once. We have been primarily guided by criteria of
popularity of careers view of career counselors.
Developing a virtual class room system to promote a greater count of students to
splurge into field of education. It integrates benefits of physical classroom with
convenience of a no physical-bar virtual learning environment minus commuting
hazard & expenses
To help visitors to access information according to the requirement regarding their
career
Non Registered User can search for different colleges and courses available there, can
view features of the portal
Registered Users can conduct online examination.
User can down load different forms of data.
4.3 Main Modules:
The whole system is divided into different module:-
4.3.1 Module 1: Admin Module
Adding Colleges
Adding college information
,Adding Courses
Upload videos
Modify Questions
Registration Reports
Adding college info
CAREER PLANNER

26

Modify college information
Report of exam result,
Add file for virtual classroom
Modify data of virtual classroom
Online feedback,
Report of register user

4.3.2 Module 2: User Module
Search for courses
Registration Form
Take online exam
Feedback Form
Search for files
Download file
Upload file
Get college info
4.3.3 Module 3: Search Module
Search Courses
Search Colleges
Search data for virtual classrooms
4.3.4 Module 4: Database Design
DFD
Relationship

4.4 Feasibility Analysis:
A feasibility study is conducted top select the best system that meets performance
requirement. Feasibility analysis is the procedure for identifying the candidate system,
evaluating and electing the most feasible system. This is done by investigating the existing
system in the area under investigation or generally ideas about a new system. It is a test of a
system proposal according to its workability, impact on the organization, ability to meet user
CAREER PLANNER

27

needs, and effective use of resources. The objective of feasibility study is not to solve the
problem but to acquire a sense of its scope. Feasibility analysis involves 8 steps:
Form a project team and appoint a project leader.
Prepare system flow charts
.Enumerate potential candidate system.
Describe and identify characteristics of candidate systems.
Determine and evaluate performance and cost effectiveness of each candidate system.
Weigh system performance and cost data.
Select the best candidate system.
Repair and report final project directive to management.
Three key considerations are involved in the feasibility analysis: economic, technical and
behavioral.
Economic feasibility:
Economic analysis is the most frequently used method for evaluating the effectiveness of a
candidate system. It is more commonly known as cost benefit analysis, the procedure to
determine the benefits and saving that are expected from a candidate system and compare
them with costs. If the benefits outweigh costs then a decision is made to design and
implement the system. Otherwise make alterations in the proposed system. In this feasibility
study we consider following costs:
Cost to conduct full system investigation.
Cost of hardware software for class of application being considered.
The benefit in the form of reduced cost
Technical feasibility:
The assessments of technical feasibility centers on the existing system and to what extent it
can support the proposed addition. This was based on an outline design of system
requirements in turns of inputs, files, programs, procedures, and staff. It involves financial
considerations to accommodate technical enhancements. It studies the resources availability
that may affect the ability to achieve an acceptable system. This system can be made in any
CAREER PLANNER

28

language that support good user interface any easy database handling. This evaluation
determines whether the technology needed for the proposed system is available or not.
Behavioral feasibility:
People are inherently resistant to change, and computers have been known to facilitate
change. An estimate should be made about the reaction of the user staff towards the
development of a computerized system. Computer installations have something to do with
turnover, transfers and changes in job status. The introduction of a candidate system requires
special effort to educate, sell and train the staff for conducting the business.
Software Reference table:

S.No Software
Name
URL USP Price
1. Visual
Studio
Web
Developer
www.microsoft.com/visualstudio/en-
us/products/2008-editors/visual-web-developer
Consists of
advanced
inbuilt
function
for
developing
web
application

2. SQL
Server
2008
www.microsoft.com/sqlserver/en/us/sq/server/2008 Use ACID
property

Table: 4.4.1 Software reference table
4.5 System Life Cycle:
The following approach is used to deign this system , which is called classic life cycle or
waterfall model .This linear sequential model suggests a systematic ,sequential approach to
software development that begins at the system level and progress through analysis , design,
coding, testing and maintenance . The linear sequential model encompasses the following
activities:-
System / information engineering and modeling
Software requirements analysis
Design
Code generat
CAREER PLANNER

29

Testing
Maintenance
4.5.1 For registration of New user in Career Planner:


Fig: 4.5.1 Registration of new user in Career planner








D
Forget Pass1
User Id
Check
User
Id
Select
Secret
Quest
If Not Member
Check
Secret
Ans
If Correct
Ans
Message: Your
Password is---

Forget Pass2
Your Secret Quest is:
Enter Secret Ans
CAREER PLANNER

30

4.5.2 For change password

Fig: 4.5.2 Change password










E
Change Password Form
Enter Old User Id
Enter New Password
Enter New Password
Check
Old
Password
If Match
Else
If there in
D.B
Message: your
Password has been
Changed
Check
Old
Usser id
and pas
Else
CAREER PLANNER

31

4.6 General Architecture of Project:


Fig: 4.6 General Architecture of Career planner

4.7 Data Flow Diagram:
A data-flow diagram (DFD) is a graphical representation of the "flow" of data through an
information system. DFDs can also be used for the visualization of data processing
(structured design).On a DFD, data items flow from an external data source or an internal
data store to an internal data store or an external data sink, via an internal process.
Data Transformation

Temporary Data Storage

Data Flow

user

View portal

Search
courses
View
colleges and
their
information
create
account
Download
videos
Online
Exam
CAREER PLANNER

32

System Analysis: - An evaluation of the current system in response to a problem or
new opportunity to determine if the current system should be modified or a new
system developed.
System Design: A physical design of a proposed system is developed
System Development: The Organization installs and begins to use a new system
System Implementation: The Organization installs and begins to use a new system
System Maintenance: The system is continually monitored and adjusted as needed
until it is time for a total revaluation.
4.8 LOGICAL AND PHYSICAL DESIGN:-
4.8.1 System Flow Chart:-
A System flow chart is a diagram that shows a broad overview of the data flow and sequence
of operations in a system. This emphasis on input document and output records, only limited
detail is furnished about how a work station or machine converts input data into the desired
output.
0 Level DFD



Fig: 4.8.1.1 Admin role








Our product:Career Planner
Admin/
User
Manages all activities
which provide help in
education
CAREER PLANNER

33

Level 1(Admin module)





















Fig: 4.8.1.2 Level-1 DFD of Admin






User level dfd
Admin

Login
Modify/
Update
Portal
Add/
Modify
Advertise-
ment
Update
Content
Verify
register
user

Log Out
Update Portal
Add/
Modify
category
CAREER PLANNER

34

View
Tour
Virtual
classroom
View colleges
Cart
Exit

Login
New users fill Form for
registration
View result


Exit
Conduct
exam


Registered
user login
Logout
User
Online
exam
Account
creates
View/download
videos
View course

Fig: 4.8.1.3 0-Level DFD for User



4.9 E-R Diagram:
CAREER PLANNER

35

An entity-relationship (ER) diagram is a specialized graphic that illustrates the
interrelationships between entities in a database. ER diagrams often use symbols to represent
three different types of information.
Boxes: Boxes are commonly used to represent entities.
Diamonds: Diamonds are normally used to represent relationships
Ovals: Ovals are used to represent attributes.
Multivalued Attributes are represented by double ovals.

4.9.1 Registered Users ER Diagram:

















Fig: 4.9.1 Registered User ER diagram

4.9.2 Non Registered Users ER Diagram
Virtual
classroom
View
View
Online exam
Take
test
Result
Downloa
d videos
Upload
videos
Account
Change password
Registered
user View
Verify
Career
College info Courses
College name
Address
Phone no
URL
Location
CAREER PLANNER

36










Fig: 4.9.2 Non Registered Users ER Diagram

4.9.3 Login ER diagram











Fig: 4.9.3 ER Diagram for login


4.9.4 Online Exam

Virtual
classroom
View
View
Account
Non
Registere
d user
View
College info
Colleges
Course
s
Create
Career
Online Exam
Username
Emailid
State
Password
Login

New
account
Forgot
password
Security ques
Answer
Password
Contact no
Country
Confirm password
Address
CAREER PLANNER

37










Fig: 4.9.4 ER Diagram for Online Exam

4.9.5 Virtual Classroom









Fig 4.9.5 ER Diagram for Virtual Classroom



4.10 DATABASE DESCRIPTION

Online
exam
Choose Subject
Subject name
Subject id
Click
Instruction
Test
Exam
Submit
Result
Download
Virtual classroom
Select
File type
Subject
Upload

Url
Subject type
Subject id
File type
Subject
CAREER PLANNER

38


Fig: 4.10.1 Database


Fig: 4.10.2 Database of Courses
CAREER PLANNER

39



Fig: 4.10.3 Database of Online Exam



Fig: 4.10.4 Database of BBA Course
CAREER PLANNER

40


Fig: 4.10.5 Database of DSA Online Exam



Fig: 4.10.6 Database of User Information
CAREER PLANNER

41



Fig: 4.10.7DataBase of ASP pdf file for Virtual Classroom


Table 4.10.8 Database of BBA College
4.11 PERT (Performance Evaluation and Review Technique)
CAREER PLANNER

42

Like Gantt chart PERT also makes use of tasks. It shows achievement. These achievements
are however not tasking achievement. They are terminal achievement called events. Arrow is
used to represent tasks and the circle represents the beginning or completion of the task. The
PERT chart uses paths and events to show the interrelationship of project activation.
Task
a. Design Forms
i. Design home page
ii. Design Change Password Page
iii. Design Forget Password page
b. Design front end
i. Design Login
ii. Design Forget Password
iii. Design Change Password
iv. Design New User Signup
v. Link middle ware with Form
c. Test Program and form
d. Prepare Documentation

4.12 System Testing:
4.12.1 Objective of Testing:-
Testing is vital to the success of any system, Testing is done at different stages within the
development phase. System testing makes a logical assumption that if all parts of the system
are correct, the goals will be achieved successfully, inadequate tests or no testing leads to
errors that may come up after when correction would be extremely difficult. Another
objective of testing is its utility as a user-oriented vehicle before implementation. The testing
of the system was done on both artificial and live data .The following types of tests are
performed.
Unit Testing: This testing focuses verification on the module .using procedural design
description as a Guide; important control paths are tested to uncover errors within the
boundaries of the module. The relative complexity of tests and uncovered errors is
CAREER PLANNER

43

limited by the constraints scope established for unit testing. The unit testing can be
conducted in parallel for several modules.
Integration Testing: Generally a combined approach known as sandwich testing using
features of top down testing strategy for upper levels of the program structure,
coupled with the bottom up strategy for subordinate modules.
Functional testing: This is done for each module/sub module of the system.
Functional testing serves as a means of means of validating weather the functionality
of the system confers the original user requirement i.e. done the module do what is
supposed to do. Separate schedules were made for functional testing .it involves
preparation of bugs listing for non-conformities.
System Testing: System testing is done when the entire system has been fully
integrated. The purpose of the system testing is to test how the different modules
interact with each other and whether the system provides the functionality that was
expected.
It consists of the following steps.
Program Testing
String Testing
System Testing
System Documentation
User Acceptance Testing

CAREER PLANNER

44

CHAPTER 5
SNAPSHOTS
Snapshots1: Home page

Fig 5.1 Representing home page of the career planner

Snapshots2: Login page

Fig 5.2 Representing login page
Snapshots3: Signup page for a new user
CAREER PLANNER

45


Fig 5.3 Representing signup page

Snapshots4: Career module showing information about colleges providing different
courses

Fig 5.4: Representing best colleges in Jaipur for different fields
Snapshots5: Top engineering college with details
CAREER PLANNER

46


Fig 5.5: Representing best engineering colleges in Jaipur with their details

Snapshots6: Virtual classroom &online exam

Fig 5.6 Virtual classroom & online exam
Snapshots7: Subject selection for online exam conduction
CAREER PLANNER

47


Fig 5.7 Subject selection

Snapshots8: Question for online exam

Fig 5.8 Questions for the exam
Snapshots9: Result declaration of online exam
CAREER PLANNER

48


Fig 5.9: Representing the result

Snapshot10: Virtual classroom showing type of files available

Fig 5.10: Representing different types of file
Snapshot11: Showing subjects with different file format which can be downloaded
CAREER PLANNER

49


Fig 5.11: Representing Html ppt files which could be downloaded

Snapshot12: Showing definition of colleges which provide animation course

Fig 5.12: Table definition of colleges which provide animation course

CAREER PLANNER

50

Snapshot13: Showing definition of user information

Fig 5.13 Table definition of user information

Snapshot14: Showing Table definition of verbal aptitude test

Fig 5.14 Table definition of verbal aptitude test

Vous aimerez peut-être aussi