Online Manager: Bachelor of Computer Application
Online Manager: Bachelor of Computer Application
Done by
                           JITHIN JOSE
                         (Reg.no:11157293)
Puthencruz-682308
                           March 2014
            ST.THOMAS ARTS & SCIENCE COLLEGE
                                PUTHENCRUZ
              (Affiliated to Mahatma Gandhi University, Kottayam)
C E R T I F I C A CT E
       It is hereby certified that this is a bona fide project work done by Jithin Jose
(Reg.No: 11157293) in partial fulfillment of the requirements for the award of the sixth
semester of Bachelor of Computer Application of St. Thomas Arts And Science College
Puthencruz of Mahatma Gandhi University, Kottayam.
      I hereby declare that the project entitled ‘Online manager’ is a bona fide
work done by me under the guidance of Mrs. Amrutha K.G, Lecturer, Dept.
of Computer Science, St. Thomas Arts & Science College,          Puthencruz, in
partial fulfillment of the requirements for the award of the degree Bachelor of
Computer Applications of St. Thomas Arts And Science College, Puthencruz
of Mahatma Gandhi University, Kottayam.
Jithin Jose
Place: Puthencruz
Date:
                          ACKNOWLEDGEMENT
      I profusely thank other Lecturers in the department and all other members
of the staff of St. Thomas Arts & Science College, Puthencruz, for their guidance
and inspiration throughout my course of study.
                                                                   Jithin Jose
                                         SYNOPSIS
      The Online Manager is a web based office software which can be accessed by any
person from anywhere in the World. The Admin is the overall control of the system and
also the users can update their status in this system.
1. Employee Registration
 2. Adding Departments
      This module involves adding of new departments to the office.
 4. Salary Calculation
      This module involves entering basic payment and its details and calculation of salary
and employee can view it
  5. Adding Notices
      Admin can add notices and employees can view it.
  6. Adding Holidays
      Admin can add holidays in the office calendar and employee can view it.
   7. Leave Requests
    Employee can sent leave requests and admin can either sanction or reject the leave
 requests.
        Login form: This form will only connect to the Admin or employee home if and
only if the username and password entered is correct. When the user enters the wrong
username or password login is failed.
        The front end of this project is ASP.NET and the back end of this project is MS SQL
Server 2008 .This project is implies to make the process in office in computerized form
CONTENTS
                                 CONTENTS
                                            PAGE NO
1. INTRODUCTION                                1
   1.1. About the organization                 3
   1.2. About the project                      4
2. SYSTEM ANALYSIS AND DESIGN
   2.1. System study                           6
      2.1.1. Existing system                   6
      2.1.2. Proposed system                   8
      2.1.3. Feasibility study                 9
3. SOFTWARE AND HARDWARE SPECIFICATION
   3.1. Operating system                       12
   3.2. Front end                              14
   3.3. Back end                               16
4. SYSTEM DESIGN                               19
   4.1. Output design                          19
   4.2. Input design                           20
   4.3. Process design                         21
      4.3.1. Data flow diagram                 22
   4.4. Table design                           29
5. SYSTEM TESTING AND IMPLEMENTATION
   5.1. System testing                         37
   5.2. System Implementation                  39
   5.3. Maintenance                            40
6. FUTURE ENHANCEMEN                           42
7. CONCLUSION 44
8. BIBLIOGRAPHY 46
9. APPENDIX
   9.1. Screen shots                           48
   9.2. Source code                            72
Bachelor of Computer Application                  Online manager
INTRODUCTION
1. INTRODUCTION
Online Manager is a web based office software which can be accessed by any
person from anywhere in the World. The objective of this software is to establish an
procedures.
Online Manager is web based office software to maintain add new employee, add
new department, add salary details, salary calculation, add punch in and punch out
not be very keen on spending loads of money on ledgers. Whereas our product will
greatly reduce the running by using common and cheap office items like database and
desktop application. And also there is no requirement to store books or accounts. The
data is directly stored in the database in the hard disk of the PC.
       CuteSys Technologies Pvt. Ltd. is a frontline software company in Cochin, India. It has
  a team of experienced Software experts who are dedicated to deliver high quality Projects. It
  has clients across the globe and there are many software Products in various domains.
 The company is so popular that the clients feed the company with repeat orders, having faith
 in the capabilities. The staff includes management and engineering personnel, programmers,
 web developers, graphic designers, business analysts, Technical writers etc, apart from the
 regular commercial and administrative hands.
        They are committed to provide what they have promised. They strive for the
 satisfaction of their clients and dedicate themselves for the better services to their customers.
 They are famous in providing high quality, cost cutting, requirement oriented and value
 added web and software solutions with remarkable cyber services. They are specialist in
 developing ever rewarding internet existence for ambitious companies which are in the
 hangover of swift moving internet facilities. Their aim is to grow with such organizations n a
 very fruitful manner.
        Their main concentration is to collect business oriented technological know-how and
 utilize them for the wellbeing of business concerns. Their experts in various technologies are
 committed to deliver effective and creative service to customers.
Specializations
 Web portals
 E-Commerce
            Online Manager is a web based office software which can be accessed by any
 person from anywhere in the World. The objective of this software is to establish an
 employee-employer relationship easy by systematic digital communication procedures.
 There are mainly 2 end users to this application, (1) Employees (also called Users), (2)
 Employers (also called Admin). Users can make upward-communications of their official
 routine processes to their employer and the employer can make downward-communications
 through this software. Reports are generated based on various criteria. Employees can login
 to view their attendance and salary. Thus all manual process that is to be done in an office is
 reduced to a considerable extent.
 Online Manager is a web based office software which can be accessed by any person from
 anywhere in the World. The objective of this software is to establish an employee-
 employer relationship easy by systematic digital communication procedures.
 Users: Employees of the office are the users of this system. They can punch-in and punch-
 out in right timings and also can upload their works very easily. They can view notices,
 holidays. They can also sent complaints and view its solutions.
                      SYSTEM ANALYSIS
                         AND DESIGN
      Analysis is a detailed study of the various operations performed by a system and their
 relationships within and outside the system. One aspect of analysis defining the boundaries of
 the system and determining whether or not a candidate should consider other related systems.
 During analysis, data is collected from the available files, decision points, and transactions
 handled by the present system
      In the current scenario the overall management in an office is done by the help of excel
 workbooks and mails. Considering an office with large number of employees and operations
 it is difficult to understand the sequential flow of the mails and the worksheets, this may lead
 to conflicts. Also the work status updating procedures consume time of personnel’s thus
 decrease the productivity of the organization.
     Productivity:
        Productivity is usually lower, particularly in routine or operational situations such as
        transaction processing.
     Slower:
        Processing is slower where large volumes of data need to be dealt with. Slower
        processing means that some information that could be provided if computerized
        systems were used will not be provided at all, because there is no time.
     Risk of Errors:
        The risk of errors is greater, especially in repetitive work like payroll calculation.
     Less accessible:
        Information is generally less accessible. Access to information is often is restricted to
        one user at a time, paper files can easily be mislead in trays, in which case the
        information they contain is not available to all.
     Bulk:
        Paper based systems are generally very bulky both to handle to store and shop space
        are expensive.
     Alterations:
        It is difficult to make corrections. If a manual documents contains errors or need
        updating it is often necessary to recreate the whole document from scratch, rather than
        just a new version with the relevant details changed.
     Quality of output:
        Quality of output is less consistent and often not well designed. At worst, hand written
        records may be illegible and so completely useless. Poorly presented information may
        fail to communicate key points.
     Time and manpower:
        Report generation various area is done manually using great amount of manpower and
        time. Erroneous records may lead to misleading information, which is more likely in
        manual system.
     Less User-friendly:
        The existing system involves readability of the records; Maintenance of billing details,
        sales information etc. The technique is used in existing system is more complicated
        and there is lack of technical background towards the system and also it’s less user-
        friendly.
         The Online Manager is a web based office software which can be accessed by any
  person from anywhere in the World. The Admin is the overall control of the system and also
  the users can update their status in this proposed system.
          In order to overcome the drawbacks in the existing system, database is created which
 is integrated, reliable, consistent, flexible and secure. The features of the proposed database
 are:
             After the problem is clearly understood and the solutions are proposed, the next
 step is to conduct the feasibility study, which is a part of system analyses well as system
 design process. The main objective of the study is to determine whether the proposed system
 is feasible or not. Manley there are three types of feasibility study to which the proposed
 system subjected as described below. Three key considerations are involved in the feasibility.
  I.      Economic feasibility
 II.      Technical feasibility
III.      Behavioral feasibility
       The proposed system must be evaluated from a technical view point first and of technical
 feasibility, their impact on the organization must be accessed. If compatible, behavioral
 system can be devised. Then they must be tested for economical feasibility.
Economic feasibility:
       Justification of any capital outlay is that it will reduce expenditure, improve the quality
 of service of goods, which in turn may be expected to provide increased profits. The
 technique of cost benefit analysis is often used as a basis for accessing economic feasibility.
 The project Online Manager, after implementation will result in minimum cost. It was seen
 that the cost of proposed system could be handled by the organization. And when compared
 with the cost, benefits on the implementation of the system are more, and so it is very much
 feasible.
Technical feasibility:
       The assessment of technical feasibility must be based on an outline design of systems
 requirements in terms of inputs, output, files, programs and procedures this can be qualified
 in terms of volumes of data, trends, frequency of update, cycles of activity etc, in order to
 give an introduction of technical system.
 Technical feasibility was done to analyze whether the organization have requirements that is
 needed for the system implementation. The system is a web application that uses ASP.net for
 development. It uses C# as the front end and SQL server management 2008 as the back end.
 The system works well in the organization, since it satisfies the minimal requirements for the
 working of the system
Behavioral feasibility:
      People are inherently resisted to change and computers have been known to facilitate
 change. Since the new proposed system is nothing to do with the ordinary customers, the
 worker resistance to the system is very much less. The users might be scared of job losses
 and other problems when a new system is introduced.
             SOFTWARE
                AND
        HARDWARE SPECIFICATION
       Windows 7 provides reliability and scalability. Lower your cost of computing with
 powerful, flexible management services, and provides the best foundation for running
 business applications. The system information is broken into several main categories and
 subcategories.
        The software environment category is used to display the software that is loaded in
 your computer’s memory. This includes any drivers, print jobs, running tasks, loaded
 modules, program groups and startup programs. This information is useful for determine
 what is being loaded into, and possibly using too much, memory.
Software specification
Hardware specification
 Microprocessor : Pentium 4
 RAM : 128 MB
 Hard Disk : 40 GB
 CD Drive : 52
ASP.NET
    ASP.NET Web pages, known officially as Web Forms, are the main building blocks 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 rc 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).
  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 (which means the
 developer need not perform a separate compilation step for pages). This feature provides the
 ease of development offered by scripting languages with the performance benefits of a
 compiled binary. However, the compilation might cause a noticeable but short delay to the
 Web user when the newly edited page is first requested from the Web server, but will not
 again unless the page requested is updated further.
    The ASPX and other resource files are placed in a virtual host on an Internet Information
 Services server (or other compatible ASP.NET servers; see Other implementations, below).
 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.
 Developers can also choose to pre-compile their "code behind" files before deployment,
 using Microsoft Visual Studio, eliminating the need for just-in-time compilation in a
 production environment.[citation needed] This also eliminates the need of having the source
 code on the Web server. It also supports pre-compile text.
The system has been developed in Microsoft SQL Server 2008 as back end.
      SQL Server 2008 was released on August 6, 2008 and aims to make data management
 self-tuning, self organizing, and self maintaining with the development of SQL Server
 Always On technologies, to provide near-zero downtime. SQL Server 2008 also includes
 support for structured and semi-structured data, including digital media formats for pictures,
 audio, video and other multimedia data. In current versions, such multimedia data can be
 stored as BLOBs (binary large objects), but they are generic bit streams.Intrinsic awareness
 of multimedia data will allow specialized functions to be performed on them. According to
 Paul Flessner, senior Vice President, Server Applications, Microsoft Corp., SQL Server 2008
 can be a data storage backend for different varieties of data: XML, email, time/calendar, file,
 document, spatial, etc as well as perform search, query, analysis, sharing, and
 synchronization across all data types.
        Relational database systems are the most important database used in the software
 industry today. One of the most outstanding systems is Microsoft SQL Server. SQL Server is
 a database management system developed and marked by Microsoft. It runs exclusively
 under Windows NT and Windows 95/98.
 Query optimization
 Data integrity
 Concurrency control
 When creating a database, the main concept is to know how the database is structured in
 SQL.
 SQL stands for Structured Query Language. It is a language that enables us to create and
 operate on relational database, which are sets of related information stored in tables. Because
 of its elegance and independence from machine specific, as well as its supports by the
 industry leaders in relational database technology, SQL has become the standard language
 and will remains as it is for the foreseeable future.
 There are two types of SQLs-interactive and embedded. Interactive SQL is used to operate
 directly on a database to produce output for human consumption. Embedded SQL consists of
 SQL commands put inside of programs that are mostly written in some other languages such
 as COBOL, Pascal, and C etc. This can make programs more powerful and efficient. The
 functional categories of SQL commands consist of DDL and DML.
SYSTEM DESIGN
4. SYSTEM DESIGN
      System design’s main aim is to identify the modules that should be in the
 system, and the specifications of these modules and how they interact with each
 other to produce the desired results. At the end of the system design all the major
 data structures, file formats and the major modules in the system and their
 specification are decided.
            Efficient and transport output design improves the system relationship with the user
 and help him to understand faster. A complicated output design contributes nothing to the
 system but leave the user confused. For a successful system it is a must that it maintains a
 clear output design. The users of the output its purpose and sequence of details to be printed
 are all considered. The output form is system is the justification for its existence. If the
 outputs are inadequate in any way the system itself is inadequate. The basic requirements of
 content medium and layout for its intended purpose. Hence it is necessary to design output so
 that the objectives of system are met in the best possible manner. The output is in the form of
 reports.
 Output design is a process that in valves designing necessary output in the form of reports
 that should be given to the users according to the requirements. While designing the output,
 the following steps are to be considered:
        In accurate input data is the most cause of errors in data processing. Errors by data
 entry operators can be controlled by input validation. Input design is the process of
 converting user-oriented inputs to a computer-based format. Input design is a part of an
 overall system design, which makes the system user friendly. The input design is the link
 between the information system and users. It comprises developing specifications and those
 steps that are necessary to put transaction data into a usable form for processing data entry.
 The activity of putting data into the computer for processing can be achieved by instructing
 the computer to read data from a written or printed document or it can occur by having
 people key data directly in to the system. The design of input focuses on controlling the
 amount of inputs required , controlling errors, avoiding delay, avoiding extra steps and
 keeping the process simple.
 Methods for performing input validations and steps to follow when error occur. The input
 screens are displayed in a way that the user can understand entries very easily. Proper
 validation and controlling of input data will reduce the chance of errors. All major operations
 are done only after checking the results of confirmation messages. This makes the system
 more reliable and user friendly
          The Primary goal of data base management system is to provide an environment that
 is both conventional and efficient to use in retrieving information from and storing
 information into database.
Data Model
 The entity relationship models (E-R model) is based on perception of real world, which
 consists of a set of basic objects called entities and relationships among these objects . It was
 developed in order to facilitate database design by allowing then specification of an
 enterprise scheme. Such a scheme represents the overall logical structure of database.
       A Data Flow Diagram (DFD) or a bubble chart is a graphical tool for structured
 analysis. It was De Macro in 1978 and Gene and Carson in 1979 who introducedDFD.DFD
 models a system transforms the data and creates, output data-flows which go by suing
 external entities from which data flows to a process which to other processes or external
 entities or files. Data in files many also flow to processes as inputs.
       There are various symbols used in DFD. Bubbles represent the process. Named arrows
 indicate the dataflow. External entities are represented by rectangles and are outside the
 system such as venders or customers with whom the system interacts. They either supply or
 consume data. Entities supplying data are known as sources and those that consume data are
 called sinks. Data are stored in a data store by a process in the system. Each component in a
 DFD is labeled in with a descriptive name. Process names are further identified with a
 number.
        DFD can be hierarchically organized, which help in partitioning and analyzing large
 systems. As a first step, one Data Flow Diagram can depict an entire system. Which gives the
 system overview? It is called Context Diagram of level 0 DFD. The context diagram can be
 further expanded. The successive expansion of DFD from the context diagram that giving
 more details is known as leveling of DFD. Thus of top down approach is used, starting with
 an overview and then working out the details.
       The main merit of DFD is that it can provide an overview of what data a system would
 process, what transformation of data are done, what files are used, and where the result flow.
 The data flow diagram of online manager has been represented as a hierarchical DFD context
 level DFD was drawn first.
      Then the processes were decomposed into several elementary levels and are represented
 in the order of importance.
Square:
Arrow:
 A data flow is a route, which enables packets of data to travel from one point to another. Data
 may flow from a source to a processor and from data store or process. An arrow lines depicts
 the flow, with arrowhead pointing in the direction of flow
Circle:
  A Process represents transformation where incoming data flows are changed into outgoing
 data flows.
Open rectangle:
 A data is a repository of data that is to be stored for use by one or more process may be as
 simple as buffer or queue or sophisticated as relational database. They should have clear
 names. If a process merely uses the content of store and doesn’t alter it, the arrowhead goes
 only from the store to the process. If process alters the details in the store then a double-
 headed arrow is used.
Level 1
Level 2
whole. A database is a collection if inter related data stored with minimum redundancy to
serve many quickly and effectively. It is a collection of stored data organized in such a way
number of database files were designed to hold the data requirements for running their
systems.
Id Int id
ta numeric(18, 2) Ta
                       SYSTEM TESTING
                            AND
                      IMPLEMENTATION
    System testing is the stage of implementation, which is aimed at ensuring that the system
 works accurately and efficiently before live operation commence. Testing is vital to the
 success of the system. An elaborate testing of data is prepared and the system is tested using
 this test data. While testing errors are noted and corrections are made. The users are trained
 to operate the developed system. Both hardware and software securities are made to run the
 developed system successfully in future.
Types of testing:
 1. Unit Testing
 2. Integration Testing
 3. Validation Testing
 4. Output Testing
 5. User Acceptance Testing
Unit Testing
       Unit testing focuses verification efforts on the smallest unit of software design, the
 module. This is also known as “Module Testing”. The modules are separately. This testing is
 carried out during programming stage itself. In this testing step each module is found to be
 working satisfactorily as regard to the expected output from the module.
Integration Testing
Validation Testing
Output Testing
     After performing the validation testing, the next step is output testing of the proposed
 system since no system could be useful if it does not produce the required output in the
 specific format. The output generated or displayed by the system under consideration is
 tested asking the users about the format required by them. Here, the output is considered in
 two ways: one is on the screen and the other is printed format.
 The output format on the screen is found to be correct as the format designed according to
 the user needs. For the hard copy also, the output comes out as specified by the user. Hence
 output testing doesn’t result in any connection in the system.
      User acceptance of a system is the key factor for the success of any system. The under
 consideration is tested for user acceptance by constantly keeping in touch with the
 prospective system users at a time of developing and making for ONLINE MANAGER
 The testing of the software began along with coding. Since the design was fully object
 oriented, first the interfaces were developed and tested. Then unit testing was done for every
 module in the software for various inputs, such that each line of code is once executed.
 After all modules were coded the integration test were carried out. Some minor errors were
 found in the output at the earlier stage and each of them was corrected. In the
 implementation of user interface part no major errors were found. After the software was
 completely developed, the testing was done. The output of the software were correct and
 accurate during the time of demonstration, after that no errors were reported
        Implementation is the stage in the project where theoretical is design is turned into a
 working system and is giving confidence on the new system for the users, which will work
 efficiently and effectively. It involves careful planning, investigation of the current system
 and its constraints on implementations, design of methods to achieve the change over, an
 evaluation, of change over methods. Apart from planning major task of preparing the
 implementation are education and training of users. The major complex system being
 implemented the more evolved will be the system analysis and the design effort required just
 for implementation. An implementation coordinating committee based on policies of
 individual organization has been appointed. The implementation process begins with
 preparing a plan for the implementation of the system. According to this plan, the activities
 are to be carried out discussions made regarding the equipment and resources and the
 additional equipment has to be acquired to implement the new system.
       Implementation is the final and important phase. The most critical stage in achieving a
 successful new system and in giving the users confidence that the new system will work and
 be effective. The system can be implemented only after thorough testing is done and if it
 found to working according to the specification. This method also offers the greatest security
 since the old system can take over if the errors are found or inability to handle certain type of
 transaction while using the new system.
5.3 MAINTENANCE
 Maintenance is the enigma of software development. It holds the software industry captive,
 typing up programming resources. It is perceived as requiring neither skill nor experience.
 Maintenance covers wide range of activities, including correcting, coding and design errors,
 updating documentation and test data and upgrading user support.
FUTURE ENHANCEMENT
6. FUTURE ENHANCEMENT
         The system is developed and designed such a way that further expansion or
 modification can be made to permit the evaluation. The focus of the system is to inherit the
 requirements and update the system as per the needs. This project is so perfectly designed
 that it satisfies the requirements.
CONCLUSION
7. CONCLUSION
To conclude this, I thank all people who help us to complete this project work successfully.
BIBLIOGRAPHY
8. BIBLIOGRAPHY
SOFTWARE ENGINEERING
Roger’s. Pressman
COMPLETE HTML
Steven Holzner
Jain
Evangeleous Petersons
MANAGING PROJECTS
Gwen Lowery
APPENDIX
Login
Admin home
Add calendar
Add Department
Employee Registration
Add notice
View Attendance
Salary
View complaint
Employee List
Punch in
Punch out
Employee
Login
Home
Apply leave
View Salary
View Notice
Sent complaint
View Complaint
View leave
Logout
View calendar
Add department
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data;
if (!IsPostBack)
dt = ob.fillData(t);
GridView1.DataSource = dt;
GridView1.DataBind();
ob.exeNonQuery(sql2);
txtDname.Text = "";
Response.Redirect("~//admin//adminhome.aspx");
if (e.CommandName == "Del")
Label lb = (Label)row.FindControl("depid");
GridView1.EditIndex = e.NewEditIndex;
//string id=GridView1.Rows[row].Cells[0].ToString();
dt = ob.fillData(t);
GridView1.DataSource = dt;
GridView1.DataBind();
//string s = GridView1.DataKeys[e.RowIndex].Value.ToString();
TextBoxdepname = (TextBox)GridView1.Rows[e.RowIndex].FindControl("TextBox1");
dt = ob.fillData(t);
GridView1.DataSource = dt;
GridView1.DataBind();
GridView1.EditIndex = -1;
GridView1.EditIndex = -1;
dt = ob.fillData(t);
GridView1.DataSource = dt;
GridView1.DataBind();
Employee registration
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data.SqlClient;
usingSystem.Data;
if (!IsPostBack)
DataSet d1 = obj.fillData(s);
drpDepartmnt.DataTextField = "deptname";
drpDepartmnt.DataSource = d1;
drpDepartmnt.DataBind();
drpYoe.Items.Add("select");
drpYoe.Items.Add(i.ToString());
string gender="";
if (RadioButton1.Checked==true)
gender=RadioButton1.Text;
else
gender=RadioButton2.Text;
string sql="insert into emp values('"+ txtName.Text +"','"+ txtUname.Text +"','"+ txtAddress.Text
+"','"+        txtAge.Text      +"','"+   gender   +"','"+   txtEmail.Text   +"','"+   txtPhone.Text   +"','"+
drpDepartmnt.SelectedItem +"','"+ txtDesigntn.Text +"','"+ drpYoe.SelectedItem +"')";
obj.exeNonQuery(sql);
string sql1 = "insert into login values('" + txtUname.Text + "','" + txtPwd.Text + "','user')";
obj.exeNonQuery(sql1);
Response.Write("<script> alert('Insert')</script>");
txtName.Text = "";
txtUname.Text = "";
txtPwd.Text = "";
txtAddress.Text = "";
txtAge.Text= "";
RadioButton1.Checked = false;
txtEmail.Text= "";
txtPhone.Text= "";
drpDepartmnt.Text = "select";
txtDesigntn.Text = "";
drpYoe.Text="select";
Button1.Enabled = false;
if (count > 0)
txtUname.Text = "";
txtUname.Focus();
else
Button1.Enabled = true;
Response.Redirect("~//admin//adminhome.aspx");
Log in
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Data.SqlClient;
usingSystem.Data;
obj.exeRead(sql1);
if (obj.dr.Read())
Response.Write("login sucess");
if (obj.dr["usertype"].ToString() == "admin")
Response.Redirect("~//admin//adminhome.aspx");
else
Response.Redirect("~//employ//employhome.aspx");
else
txtUname.Text = "";
txtPwd.Text = "";
txtUname.Text = "";
txtPwd.Text = "";
Punch in
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data.SqlClient;
usingSystem.Data;
if (!IsPostBack)
DataSet d1 = obj.fillData(s);
drpename.DataTextField = "username";
drpename.DataSource = d1;
drpename.DataBind();
txtdate.Text = DateTime.Now.Date.ToString("dd/MM/yyyy");
txttime.Text = DateTime.Now.ToString("hh:mm");
att = "PRESENT";
else
string s2 = drpename.SelectedItem.Text ;
SqlDataReaderdr=obj.exeRead(s1);
if (dr.Read())
Else
obj.exeNonQuery(sql);
Response.Write("<script> alert('punched')</script>");
Response.Redirect("~//admin//adminhome.aspx");
Punch out
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data.SqlClient;
usingSystem.Data;
if (!IsPostBack)
DataSet d1 = obj.fillData(s);
drpename.DataTextField = "username";
drpename.DataSource = d1;
drpename.DataBind();
txtout.Text = DateTime.Now.Date.ToString("dd/MM/yyyy");
txttime.Text = DateTime.Now.ToString("hh:mm");
att = "PRESENT";
else
string s = drpename.SelectedItem.Text;
SqlDataReaderdr=obj.exeRead(s1);
if (dr.Read())
else
obj.exeNonQuery(sql1);
obj.exeNonQuery(sql2);
Response.Write("<script> alert('punchedout')</script>");
Response.Redirect("~//admin//adminhome.aspx");
Employee leave
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data.SqlClient;
usingSystem.Data;
        // string sq1= "select name from emp where username='"+s+"'";//name is inserted into table(not
username)
// txtename.Text=obj.exeScalar(sq1).ToString();
txtdate.Text = DateTime.Now.Date.ToString("dd/MM/yyyy");
string s = Session["emp"].ToString();
stringsql = "insert into leaverequest values('" + s+ "','" + txtnofdays.Text + "','" + txtfrmdate.Text + "','"
+ txttodate.Text + "','" + txtdate.Text + "','" + txtreason.Text + "',0)";
obj.exeNonQuery(sql);
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data.SqlClient;
usingSystem.Data;
if (!IsPostBack)
DataSet d1 = ob.fillData(s1);
drpdept.DataTextField = "deptname";
drpdept.DataSource = d1;
drpdept.DataBind();
drpdept.Items.Insert(0, "Select");
stringnam = ob.exeScalar(st).ToString();
if (count == 0)
stringsql = "insert into salarydetails values('" + nam + "','" + txtbp.Text + "','" + txtda.Text + "','" +
txthra.Text + "','" + txtta.Text + "')";
ob.exeNonQuery(sql);
else
stringsql = "update salarydetails set bp='" + txtbp.Text + "'and da='" + txtda.Text + "'and hra='" +
txthra.Text + "'and ta='" + txtta.Text + "' where username='"+nam+"')";
ob.exeNonQuery(sql);
DataSet d1 = ob.fillData(s);
drpename.DataTextField = "name";
drpename.DataSource = d1;
drpename.DataBind();
Response.Redirect("~//admin//adminhome.aspx");
Add notice
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data;
publicpartialclassadmin_Addnotice : System.Web.UI.Page
Class1obj = newClass1();
if (!IsPostBack)
GridView1.DataSource = ds.Tables[0];
GridView1.DataBind();
if (rdselall.Checked == true)
CheckBoxck = (CheckBox)row.FindControl("CheckBox1");
ck.Checked = true;
//GridViewRow gr = (GridViewRow)((CheckBox)e.CommandSource).NamingContainer;
//CheckBoxchk = (CheckBox)gr.FindControl("CheckBox1");
//{
// Label lb = (Label)gr.FindControl("Label5");
// ViewState["unames"] = lb.Text;
// ViewState["dipid"] = lb1.Text;
//}
CheckBoxchk = (CheckBox)row.FindControl("CheckBox1");
if (chk.Checked == true)
Labellb = (Label)row.FindControl("Label5");
obj.exeNonQuery("insert into notice values('" + txtsub.Text + "','" + lb.Text + "','" + txtdate.Text + "','"
+ txtnotice.Text + "')");
if (rdselall.Checked == true)
CheckBoxck = (CheckBox)row.FindControl("CheckBox1");
ck.Checked = true;
else
CheckBoxck = (CheckBox)row.FindControl("CheckBox1");
ck.Checked = false;
Response.Redirect("~//admin//adminhome.aspx");
Add complaint
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
Log
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Web;
usingSystem.Web.UI;
usingSystem.Web.UI.WebControls;
usingSystem.Data;
        string sql1 = "select * from login where username='" + txtUname.Text + "' and password='" +
txtPwd.Text + "'";
obj.exeRead(sql1);
if (obj.dr.Read()
Response.Write("login sucess");
if (obj.dr["usertype"].ToString() == "admin")
Response.Redirect("~//admin//adminhome.aspx");
else
Response.Redirect("~//employ//Emplhome.aspx");
else
//Response.Write("login unsucessfull");
txtUname.Text = "";
txtPwd.Text = "";
txtUname.Text = "";
txtPwd.Text = "";