Electricity Bill Project Report

July 8, 2017 | Author: Mayuri Verma | Category: Feasibility Study, Databases, Relational Database, Microsoft Access, Graphical User Interfaces
Share Embed Donate


Short Description

Download Electricity Bill Project Report...

Description

Electricity Billing System

1.

INTRODUCTION:

1.1 Introduction to Proposed System Our project entitled “Electricity Billing System” aims is to generate electricity bill with all the charges and penalty. Manual system that is employed is extremely laborious and quite inadequate. It only makes the process more difficult and hard. The aim of our project is to develop a system that is meant to partially computerize the work performed in the Electricity Board like generating monthly electricity bill, record of consuming unit of energy, store record of the customer and previous unpaid record. We used Microsoft Visual Basic 6.0 as front end and MS-Access 2000 as back end for developing our project. Visual Basic is primarily a visual design environment. We can create a VB application by designing the form and that make up the user interface. Adding visual basic application code to the form and the objects such as buttons and text boxes on them and adding any required support code in additional modular. Microsoft Access 2000 is a powerful relational database application with which a desktop user can efficiently create and manipulate database systems. Access targets the desktop category and works best for individuals and workgroup Managing megabytes of data for multi-user access to the same database, Access uses file-server architecture, rather than client-server architecture.

Electricity Billing System

Access is included in the professional and developer editions of Microsoft office. The overall project report is divided into some parts. These parts are further divided into their subparts. In the parts we have described the purpose, scope of the project, objective of the project i.e. approach which used for developing this software. It includes the topics like the problems with the existing system and the functionality of the organization. Introduction to tools, design, coding, testing and debugging of the system are discussed in very detail. We have also provided the names of the books from which we have taken guidance to complete the work. Last section contains the matter about the overall work performed and the efforts taken to complete the project.

Electricity Billing System

2. SYSTEM STUDY: 2.1 Scope: Our project aims at Business process automation, i.e. we have tried to computerize various processes of Electricity Billing System. In the sector of electricity board we have computerizes their department and stock maintenance. Scope of any software depends upon the following things: 1. It satisfy the user requirement 2. Be easy to understand by the user and operator 3. Be easy to operate 4. Have a good user interface 5. Be expandable 6. Delivered on schedule within the budget. We have tried to make such type of software, which satisfy the above given requirement.

2.2 Objectives Of The System: The firm handles all of the work manually, which is very tedious and mismanaged. The objective of our project is as follows: a. To keep the information of Customer. b. To keep the information of consuming unit of energy of current month.

Electricity Billing System

c. To keep the information of consuming unit of energy of previous month. d. To keep the information of employee working in the department. e. To maintain the record of the department.

Electricity Billing System

3. SYSTEM ANALYSIS: 3.1 Identification Of Problem: The old manual system was suffering from a series of drawbacks. Since whole of the system was to be maintained with hands the process of keeping, maintaining and retrieving the information was very tedious and lengthy. The records were never used to be in a systematic order. there used to be lots of difficulties in associating any particular transaction with a particular context. If any information was to be found it was required to go through the different registers, documents there would never exist anything like report generation. There would always be unnecessary consumption of time while entering records and retrieving records. One more problem was that it was very difficult to find errors while entering the records. Once the records were entered it was very difficult to update these records. In present, work done in the electricity board is performed manually which is a great headache for the department .The reason behind it is that there is lot of information to be maintained and have to be kept in mind while running the business .For this reason we have provided

features

Present

system

is

partially

automated

(computerized), actually existing system is quite laborious as one has to enter same information at three different places. Following points should be well considered-: Documents and reports that must be provided by the new system: there can also be few reports, which can help management in decision-

Electricity Billing System

making and cost controlling, but since these reports do not get required attention, such kind of reports and information were also identified and given required attention. Details of the information needed for each document and report. The required frequency and distribution for each document. Probable sources of information for each document and report. With the implementation of computerized system, the task of keeping records in an organized manner will be solved. The greatest of all is the retrieval of information, which will be at the click of the mouse. So the proposed system helps in saving the time in different operations and making information flow easy giving valuable reports.

3.2 Feasibility Study: Feasibility study is the phase in which the analyst checks that the candidate system is feasible for the organization or not. This entails identification, description & evaluation of the system. Feasibility study is done to select the best system that meets the performance requirement. If the feasibility study is to serve as a decision document, it must answer key questions. 1. Is there a new and better way to do the job that will benefit the user? 2. What are the costs and savings of the alternatives? 3. What is recommended?

Electricity Billing System

The most successful system projects are not necessarily the biggest or most visible in the business but rather those truly meet user’s expectations. Feasibility considerations Three key considerations are involved in the feasibility study. They are as follows:Economic Feasibility: Economic analysis is the most frequently used method for evaluating the effectiveness of the candidate system. We analyze the candidate system (computerized system) is feasible as than the manual system because it saves the money, time and manpower. It also feasible according to cost benefits analysis. Technical Feasibility: Technical feasibility centers around the technology used. It means the candidate system is technically feasible i.e. it don’t have any technical fault and work properly in the given environment. Our system is technically feasible; it is providing us required output. Behavioral Feasibility: Behavioral feasibility is the analysis of behavior of the candidate system. In this we analyze that the candidate system is working properly or not. If working than it

communicating proper

with the environment or not. All this matters are analyzed and a good candidate system is prepared. Due to the change of system what is the change in behavior of the users, this factors are also analyzed.

Electricity Billing System

4. SYSTEM DEVELOPMENT ENVIRONMENT: System development environment shows the hardware and software requirement, which is necessary for developing the software. Necessary software and hardware requirement, which are necessary for making this software are as follows:

4.1 Software Requirement: Software requirement for developing this project is as follows: Microsoft Visual Basic 6.0 Microsoft -Access 98 or higher version. Windows 98 or higher version.

4.2 Hardware Requirement: Hardware requirement for developing this project is as follows: 1.

Intel Pentium Processor

2.

32 MB RAM or higher

3.

1.2 GB Hard Disk or greater.

4.

Video Display Unit.

5.

Keyboard.

6.

Mouse.

7.

One Printer for printing the electricity bill.

Electricity Billing System

5. INTRODUCTION TO TOOLS: 5.1 Introduction of Visual Basic: Over past few years visual basic 6.0 (front end) the relational data base management system has been fine-tuning it is offering a large complex application in the relational market. Visual basic 6.0 is a front end (i.e. uses graphical user interface) visual basic 6.0 uses windows environment. It may use any DBMS or RDBMS as a back-end through ODBC (open database connectivity). For our purpose of development, in our project we used Visual Basic 6.0 because visual basic 6.0 has following outstanding features and qualities. Advantages Of Visual Basic: 1. Visual Basic applications are event driven. Event driven means the user is in Control of the application. 2. Visual Basic supports the principle of object-oriented design. 3. Visual Basic is a complete window application development system. 4. Visual Basic is infinitely extensible through the use of active x controls dynamically linked libraries (dll's) and adds dins. The Fast Track To Windows Development Visual Basic is primarily a visual design environment. We can create a VB application by designing the form and that make up the user interface. Adding visual basic application code to the form and the

Electricity Billing System

objects such as buttons and text boxes on them and adding any required support code in additional modular. Friendly Environment Creating a form, adding controls to form and writing code behind the form are all managed within a friendly environment. Graphical User Interface Application developed in DOS environment has to include its own set of video, keyboard and printer drivers. in other words many DOS programs provided virtually no user interface at all. Since windows is preferable over DOS and Visual Basic is windows based hence millions of users can use applications with no documentation or training: The graphical user interface provides a graphical environment to user as front-end for their operating system through graphical objects and therefore screen looks very attractive and almost has three-dimensional qualities. The point and shoot use of a GUI (Graphical User Interface) make use of the operating system and programming easy. Visual basic 6.0 connect to number of back-end DBMS and RDBMS such as SQL, FoxPro, Sybase, Oracle etc. Open Database Connectivity Visual basic 6.0 connects to any back-end DBMS system whose DBMS cores follow the open database connectivity rules and this connectivity is established by open database connectivity.

Electricity Billing System

The data storage may belong to any DBMS engine specifically supported by visual basic 6.0 driver or any DBMS that supported open database connectivity. The data entry and validation screens are created in visual basic 6.0 connects with whichever engine is specified at the time of screen was created and manipulated data within that engine. Client server computing and visual basic 6.0: The client / server programming is also a distributed application processing and co-operating application processing. It has three distinct components, each focusing on specific job. The three components are: 1. Client application 2. A Database Server 3. A network for connecting the first two components. 1. Client Application: Client application (i.e. front end) is the part of the system that users employ to interact with data. The work of client is requesting and receiving information forms a database server (back-end). Client application can be developed rapidly using visual basic 6.0. 2. A Database Server: A Database server focuses on efficiently managing resources such as the table in which data lies. The server’s primary job is to manage the data tables optimally among multiple clients that concurrently request

Electricity Billing System

server for same resources. Visual basic can connect to a number of RDBMS that are in trend. 3. Network for connecting the first two components: A network and communication software are the vehicle that transports the data between the clients and the server. The system both client and server run communication software that allow them to talk across a network. Object Oriented Programming Approach: The visual basic 6.0 uses the OOPS approach. In OOPS, a table is treated as also object and the data being attached to as user specified parameters the forms also treated as objects for this windows object for this window object. The firing of code shippers based on events occurring such as clicking on a button via a mouse. Visual Basic Libraries: When we create commercial application we create object such as windows, data windows, menus etc. these objects that you create using an appropriate visual basic pointer are stored in libraries files. When application has to run visual basic there objects from their libraries and visual basic gives you a library painter to help you manage your libraries. Events in Visual Basic: Visual basic commercial applications are event driven. The user of the application Controls the flow of the application by the action they take.

Electricity Billing System

Visual Basic’s Debugging tool: To distribute application created in visual basic we create an executable i.e. an exe file, also there is a distribution kit to distribute the application. Features of Visual Basic: 1. Visual basic provides a GUI which and therefore screen looks very attractive. 2. Work on client / server computing model. 3. Object Oriented programming approach. 4. Visual basic provides several tool bars, which make working quick and easy. 5. It is front end and DBMS as a back end so it uses all the features of RDBMS like referential integrity foreign key etc. 6. It uses a micro help line, which visual basic uses to display starters to display information through the session. Feel Of Windows Environment Microsoft Windows environment is built-in to Visual Basic application. No need to work with any windows compatible hardware since windows provides drivers for thousand of different printer’s video adapter, modems and other peripherals.

5.2 Introduction of MS-Access Over the past several years, relational database management system have become the most widely accepted way to manage data relational system often benefits such as:

Electricity Billing System

1. Easy access to all data. 2. Flexibility in storage and modeling. 3. Reduced data storage and redundancy. 4. Independence of physical storage & logical data designs. 5. A high-level data manipulation language (SQL). 6. Tables & table operations are well defined because relational theory is founded in set theory, relational algebra & relational calculus. Our of this the reason for introducing relational model is to increase the productivity of the application programmer by eliminating the need to change application programs when a change is made to the database. As the technologies associated with RDBMS have grown rapidly in recent years, the appeal of relational databases has become apparent to a much wider audience. The phenomenal growth of the relational technology has led to more demand for RDBMS in environments ranging from personal computer to large highly secure CPU with users ranging from very casual to very sophisticated. Microsoft Access 2000 is a powerful relational database application with which a desktop user can efficiently create and manipulate database systems. Access targets the desktop category and works best for individuals and workgroup Managing megabytes of data for multi-user access to the same database. Access uses File-server architecture, rather than client-server architecture.

Electricity Billing System

Access is included in the professional and developer editions of Microsoft office. As a leader in the desktop database category, Microsoft Access makes it easy for users to find and manage their data to make better business decision. With strong integration with Microsoft Office, Access offers a similar appearance and functionality to that found in the popular Microsoft word and Excel applications for general business users, Access provides easy to use wizards throughout, such as the database wizard for getting up and running quickly and the simple query wizards for easily finding information from the data. The combination of ease of use and power in access makes it the top choice among developers who frequently use Access as a front end in a client – server scenario. The only problem with MS-ACCESS is that it cannot provide strong security features. But in front of its fast execution features this drawback can be neglected as the firm does not need any type of security whether it is operational, database, or any other security. But in application development some restriction are made of some places so that our database cannot be corrupted. MS-ACCESS is therefore used for its fast execution speed and also due to its fast connectivity. Importance of database: Growth in the usage of Computers in Business and Industrial sector initiated development of modern Database Software. Database

Electricity Billing System

software’s offers a number of potential advantages over traditional fileprocessing system; some of them are as follows: • Program-Data Independence The separation of data descriptions (metadata) from the application programs that use the data is called data-independence. With the database approach, data descriptions are stored in a central location called repository. This property of the database systems allows an organization’s data to change and evolve without changing the application programs that process that data. • Minimal Data-Redundancy The design goal with database approach is that previously separate and redundant data files are integrated into a single, logical structure. Each primary fact is recorded in only one place in the database. The database approach does not eliminate redundancy entirely, but it allows the designers to carefully control the type and amount of redundancy. • Data Consistency By controlling data redundancy, we greatly reduce the opportunities for inconsistency. In database approach updating data values is greatly simplified when each value is stored in one place only. Finally we avoid the wasted storage space that results from redundant data storage. • Data Sharing Primary advantage of database approach is sharing of data. A database is designed as a shared resource. Authorized users are granted permission to use the database and each user is provided one or more

Electricity Billing System

user views to facilitate this use. A user view is a logical description of some portion of database that is required by the user to perform some task. • Enforcement of Standards When the database approach is implemented with full management support, the database administration function should be granted single point authority and responsibility of establishing and enforcing data standards. These standards will include naming conventions, data quality standards and uniform procedures for accessing, updating and processing data. The data repository provides database administrators with powerful tools for developing and enforcing such standards. • Reduced Program Maintenance Stored data must be changed frequently for a variety of reasons: new data item types are added; data formats ate changed and so on. In file processing environment, the description of data formats and access methods inevitably result in the need to modify application programs. As a result in the change of data formats and access methods inevitably results in the need to modify application programs. In a database environment, data are more independent of application programs that use them. Within limits, we can change either the data or the application programs that use the data without necessitating the change in other factors.

Electricity Billing System

6. PRELIMINARY DESIGN OF PROPOSED SYSTEM: 6.1 Data Design: In most situations, many physical database design decisions are implicit or eliminated when we choose the database management technologies to use with the information system we are designing. Since many organizations have standard for operating systems, database management system and data access languages, we must deal only with those choices not implicit in the given technologies. The primary goal of database design is data processing efficiency. Objective Of Database Design: i) To decide on the organization of the database in computer storage and define the physical structure of the database management system. ii) To outline the program to process transactions and to generate anticipated management information and decision support reports. Designing Fields: A field is the smallest unit of application data recognized by system software Choosing Data Types:

A data type is a detailed coding schema

recognized by the system software, such as a DBMS, for representing organizational data. Selecting a data type involves four objectives that will have different relative importance for different applications: i.)

Minimized Storage Space

Electricity Billing System

ii.)

Represent All Possible Values

iii.)

Improve Data Integrity

iv.)

Support All Data Manipulations

Data Type Text Date/Time Number

Description Valid String Valid calendar date and time Number with a specified number of digits

Controlling Data Integrity For many DBMS, data integrity controls can be built into the physical structure of the fields and controls enforced by the DBMS on those fields. Some other typical controls that a DBMS may support are the following:• Default Values: A default value is the value a field will assume unless a user enters an explicit value for an instance of that field. Assigning a default value to a field can reduce data entry, time since entry of the value can be skipped and it can also help to reduce data entry errors for the most common value. • Range Control: Range control limits the set of permissible value a field may assume. The range may be a numeric lower to upper bound or a set of specific values. It is better to implement any range controls through a DBMS

Electricity Billing System

since range control in programs may be inconsistently enforced and it is more difficult to find and change them. • Null Value Control: A null value is an empty value each primary key must have an integrity control that prohibits a null value. Any other required field may also have a null value control placed on it if that is the policy of the organization. • Referential Integrity: Referential integrity on a field is a form of range control in which the value of that field must exist as the value in some field in another row of the same or different table. Record is a group of a fields stored in adjacent memory location and retrieve together as a unit. The design of a physical record involves choosing the sequencing of fields into adjacent storage location to achieve two goals that are efficient use of secondary storage of data processing speed. We have used five different tables for storing different record. There are five tables – customer table , Bill table, Bill charge table, service centre table, commercial table. Their design view are shown as follows: Table Name: BILL Field Name Bill_no BillDate

Data Type Number Date

Size Auto

Constraint Primary key

Electricity Billing System

Amount City

Number Text

Auto 30

In this table there are no multivalued attributes. So this is in First Normal Form. 2. Table Name : Customer Field Name Customer First Name

Data Type Text

Size 10

Customer Middle

Text

10

Name Customer Last Name

Text

10

Cust_id

Number

Auto

Service_Centre

Text

20

Street

Text

20

City

Text

20

City Code

Number

Auto

State

Text

20

Constraint

Primary Key

In this table there are no multivalued attributes. So this is in First Normal Form. Service Centre Table: Field Name Cust_id Service_Centre Street City City Code State

Code Design

Data Type Number Text Text Text Number Text

Design

Size Auto 20 20 20 Auto 10

Code

Constraint Foreign Key

Test

Electricity Billing System

In this table there are no multivalued attributes. So this is in First Normal Form. Bill Charge Table: Field Name Bill_no Fix _charge E_duty Total Charge Total Unit

Data Type Number Number Number Number Number

Size Auto Auto Auto Auto Auto

Constraint Primary Key

In this table there are no multivalued attributes. So this is in First Normal Form. Commercial Bill Table: Field Name Customer Name Shop_no Street Bill_no Bill Amount Bill Date

Data Type Text Text Text Integer Integer Date

Size 20 20 20 Auto Auto

Constraint Primary Key Foreign Key

These are the tables, which are used in the project development for storing different record. Every table has a primary key for storing unique record . we have also used foreign key for making relationship between the tables.

Code Design

Design

Code

Test

Electricity Billing System

6.2 Input Stream: Input stream shows the way by which information are passed in to the table as record. We have used mainly two forms in the project inputting the record in the table first is commercial bill record form and second is domestic bill record form. By these form we input the records of the table name, address, service centre, customer_id etc

6.3 Output Stream: Input stream shows the way by which information viewed by the user which are stored in the database. Commercial bill calculation form and domestic bill calculation forms are used as an output stream we can see the record and also can see the name , bill_date,total_bill etc. Commercial report form and home report form are used for getting the total record of the domestic bill and commercial bill in printed form.

7. ARCHITECTURAL DESIGN: 7.1 SDLC(System Development Life Cycle): System development life cycle is a sequence of events carried out by analyst, designers and users to develop and important an information system. Activities are carried out in different stages. The phases are as follows: 1. Preliminary Investigation (Feasibility Study) 2. Determination Of System Requirement

Electricity Billing System

3. Design Of The System 4. Design Of The System 5. Development Of Software 6. System Testing 7. System Implementation 8. System Maintenance

1. Preliminary Investigation (Feasibility Study): An important outcome of this preliminary investigation is determining whether the System requested is feasible or not. The major purpose of this study are listed below: Identify the responsible users and develop an initial scope of the system. Identify current deficiencies in the user’s environment determine objectives for the new system Determine whether it is feasible to automate the system and if so suggest some acceptable options: The three major areas to consider while determining the feasibility of a project are: 

Technical Feasibility



Economical Feasibility



Operational Feasibility

Technical Feasibility:

Electricity Billing System

The Analyst finds out whether current technical resources, which are available in the organization, is capable of Handling user requirements. Economical Feasibility: Economical or financial feasibility is second part of resource determination. Basic resources to consider are: 

Management time



Time spent by system analysis team



Cost of doing the full system study



Estimated cost of hardware



Estimated cost of software

Operational Feasibility: Operational feasibility is dependent upon determining human resources for the project. It refers to projecting whether the system will operate and be used once it is installed. The document to be produced at the end of this activity is called “FEASIBILITY STUDY REPORT” 2. Determination Of Requirements (Analysis) Determination of system requirement involves studying the current business system in Great detail to find out how it works and where improvements have to be made. This activity is carried out in two phases  Detailed investigation  Analysis or determination of system requirement

Electricity Billing System

Detailed investigation The heart of the system analysis is aimed at having a detailed understanding of all-important facts of the project under consideration. Analyst working closely with employees and managers must be able to answer the following key question: What is being done by the current system? How is being done? How frequently does it occur? How big is the volume of transactions or decisions? How well is the task being performed? Does a problem exist? If problem exists, how serious is it? If a problem exists, what is the underlying cause? To answer the above question system analyst talks to a variety of people to gather details about the project. Questionnaires are used to collect this information from large groups of people who Cannot be interviewed individually. Detailed investigations also require the study of Manual and reports, actual observation of work activities and collection of existing Forms and document to fully understand the project. Analysis or determination of system requirement It is during this phase that the analyst and the user come to an agreement on what Functions the proposed system has to perform.

Electricity Billing System

A detailed document has to prepare by system analyst containing the following: • Inputs that must be received by the system • The outputs to be produced by the system • The data to be retained • The procedures to get the output from the given inputs • Audit and control requirements • System acceptance criteria This detailed document is called functional specification or proposed procedures 3. Design Of The System The design process should take care of the following: •

Identification of reports and outputs the new system should produce.



Scrutinize the data present on each report/output



Sketch the form or display as expected to appear at the end of completion of the system. This may be done on paper or on a computer display using one of the automated system design tools description of data to be input calculated or stored individual data items and calculation procedure written in detail.



The procedures written should tell how to process the data and produce the output

The document produced at the end of this activity is called design specification 4. Development Of Software

Electricity Billing System

In this stage the actual coding / writing of the program is done. Analyst – programmers do analyst and designs well as code programs programmers are responsible for documenting the program including comments that explain both how and why certain procedure was coded in specific way. Programs are individually tested using some test data. Documentation is also essential to test the programs and carry out maintenance once the application has been installed. This activity of system development life cycle produces tested programs. 5. System Testing Once the programs are tested individually the system as a whole needs to tested. During testing the system is used experimentally to ensure that the software does not Fail that it will run according to its specifications and in the way user accept it too. special test data is prepared as input for processing and the result are examined to Locate unexpected result. 6. System Implementation in this stage the system analyst uses new software, which has been tested into use. user personnel are trained and any files of data needed by the new system are constructed. Thus new software is installed and then used. 7. System Maintenance

Electricity Billing System

Once installed the software is often used for many years. However both the organization and user change. The environment may also change over a period of time; therefore The software has to be maintained.

7.2 DFD(Data Flow Diagram): They are the versatile diagramming tools used for structured system analysis. They are specifically used for process modeling which involves graphically representing the function or process, which captures, manipulate, store, and distribute data between a system and its environment and between components within a system.

7.3 CONTEXT DIAGRAM: This is the start point of data flow diagramming process. It is denoted as the highest-level diagram. It gives an overview of an organizational system that shows the system boundaries, external entities that interact with the system and the major information flows between the entities and the system

8. DETAIL DESIGN OF PROPOSED SYSTEM: 8.1 MODULE: There are mainly four module in our project. These are as follows: 1. Domestic bill information module. 2. Commercial bill information module. 3. Domestic customer record module.

Electricity Billing System

4. Commercial customer record module.

1. Domestic Bill Information Module: In this module, we can see information related to the domestic bill like customer’s name, address, its customer id, service centre, his electricity bill description, which contain bill no, bill date, total bill etc. we can also calculate total bill of the customer according to total unit, bill charge of the bill. 2. Commercial Bill Information Module: There is no difference between domestic bill information module and this module except that, this module is for commercial purpose. We can see information related to the commercial bill like customer’s name, shop no, address, its customer id, service centre his electricity bill description, which contain bill no, bill date, total bill etc. we can also calculate total bill of the customer according to total unit, bill charge of the bill.

3. Domestic Customer Record Module: In this module, we can create the record related to the domestic customer like his name, address, customer id. This module can also perform deleting a record modifying existing record etc 4. Commercial Customer Record Module:

Electricity Billing System

In this module, we can create the record related to the customer like his name, address, customer id. This module can also perform deleting a record, modifying existing record etc. We can also see the existing record by next and previous button.

LOGIN FORM

Electricity Billing System

MDI FORM OF PROJECT

Electricity Billing System

DESCRIPTION FORM FOR ELECTRIC CHARGES

Electricity Billing System

DOMESTIC BILL CALCULATION FORM

Electricity Billing System

COMERCIAL BILL CALCULATION FORM

Electricity Billing System

DOMESTIC CUSTOMER RECORD FORM

Electricity Billing System

COMMERCIAL BILL RECORD FORM

Electricity Billing System

DOMESTIC BILL REPORT FORM

Electricity Billing System

COMMERCIAL BILL REPORT FORM

Electricity Billing System

8.2 DATA DICTIONARY: This is normally represented as the data about data. It is also termed as metadata some times which gives the data about the data stored in the

Electricity Billing System

database. It defines each data term encountered during the analysis and design of a new system. Data elements can describe files or the processes. Following are some major symbols used in the data dictionary •

= equivalent to

• + and • [] either/ or • () Optional entry Following are some rules, which defines the construction of data dictionary entries: 1.

Words should be defined to understand for what they

need and not the variable need by which they may be described in the program . 2.

Each word must be unique. We cannot have two

definition of the same client. 3.

Aliases or synonyms are allowed when two or more

enters shows the same meaning. For example a vendor number may also be called as customer number. 4.

A self-defining word should not be decomposed. It means

that the reduction of any information in to subpart should be done only if it is really required that is it is not easy to understand directly.

Electricity Billing System

Data dictionary includes information such as the number of records in file, the frequency a process will run, security factor like pass word which user must enter to get excess to the information.

9. CODING:

Electricity Billing System

9.1 Coding of Login Form: Private Sub cmdCancle_Click() End End Sub Private Sub cmdOk_Click() If txtPassword.Text = "reema" Then Loginform.Hide MDIForm1.Show Else MsgBox "invalid password", vbOKOnly, "alert" txtname.Text = "" txtPassword.Text = "" txtname.SetFocus End If End Sub

9.2 Coding of MDI Form: Dim RetVal Private Sub MDIForm_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single) If Button = vbRightButton Then MDIForm1.PopupMenu mnuEnd End If End Sub Private Sub mnuEndexit_Click() Unload Me End Sub Private Sub mnuExit_Click() End End Sub Private Sub mnuFileCombilFrm_Click() Comercialbillfrm.Show End Sub Private Sub mnufilecomreport_Click() comercialreport.Show End Sub Private Sub mnuFileCusRecfrm_Click() domRecfrm.Show End Sub Private Sub mnuFileDBillfrm_Click()

Electricity Billing System

dombillcalfrm.Show End Sub Private Sub mnuFileDesfrm_Click() descriptionfrm.Show End Sub Private Sub mnufilehomerep_Click() homebillreport.Show End Sub Private Sub mnufileopencomercialrec_Click() comercialrecfrm.Show End Sub Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button) Select Case Button.Key Case Is = "topen" descriptionfrm.Show Case Is = "texit" Unload Me End Select End Sub

9.3 Coding of Commercial Bill Calculation Form Dim u, u1 As Long Dim X, Y, s, d1, d2, d, f As String Private Sub cmdcclear_Click() txtcfix.Text = "" txtced.Text = "" txtctotal.Text = "" txtced.Text = "" txtcsc.Text = "" txtcec.Text = "" txtcunit.Text = "" txtcunit.SetFocus End Sub Private Sub cmdcexit_Click() End End Sub Private Sub cmdclear_Click() txtName.Text = "" txtAddress.Text = "" txtScenter.Text = ""

Electricity Billing System

txtBillmonth.Text = "" txtBilldate.Text = "" txtBddate.Text = "" txtTotalbill.Text = "" txtShopno.Text = "" txtBillpay.Text = "" End Sub Private Sub cmdcOk_Click() If txtcunit.Text = "" Then MsgBox "please enter unit" txtcunit.Text = 0 End If txtcfix.Text = "Rs 100.00" f = 100 u = CInt(txtcunit.Text) If u 100 Then X = 100 * 4 d1 = (X * 11) / 100 u1 = u - 100 Y = u1 * 4.25 d2 = (Y * 11.5) / 100 d = d1 + d2 txtcec.Text = "Rs" & (X + Y) s = u * 0.1 txtcsc.Text = "Rs" & s txtced.Text = "Rs" & d End If txtctotal.Text = "Rs" & (X + Y + s + d + f) End Sub Private Sub cmdOk_Click() If txtBillpay.Text = "" Then txtTotalbill.Text = txtctotal.Text Else txtTotalbill.Text = "Rs" & (X + Y + s + d + f) - Val(txtBillpay.Text) End If End Sub

Electricity Billing System

Private Sub cmdprevious_Click() Comercialbillfrm.Hide MDIForm1.Show End Sub Private Sub Form_Load() End Sub

9.3 Coding of Domestic Bill Form: Private Sub cmd1First_Click() adocom.Recordset.MoveFirst adobill.Recordset.MoveFirst cmd1First.Enabled = False cmd4Last.Enabled = True End Sub Private Sub cmd2Next_Click() adocom.Recordset.MoveNext adobill.Recordset.MoveNext cmd1First.Enabled = True cmd4Last.Enabled = True If (adocom.Recordset.AbsolutePosition) = adPosEOF And adobill.Recordset.AbsolutePosition = adPosEOF Then MsgBox ("no other record") adocom.Refresh adobill.Refresh End If End Sub Private Sub cmd3Previous_Click() adocom.Recordset.MovePrevious adobill.Recordset.MovePrevious cmd1First.Enabled = True cmd4Last.Enabled = True If adocom.Recordset.AbsolutePosition = adPosBOF And adobill.Recordset.AbsolutePosition = adPosBOF Then MsgBox ("no other record") adocom.Refresh adobill.Refresh End If End Sub Private Sub cmd4Last_Click() adocom.Recordset.MoveLast

Electricity Billing System

adobill.Recordset.MoveLast cmd1First.Enabled = True cmd4Last.Enabled = False End Sub Private Sub cmdDelete_Click() Dim res As String res = MsgBox("you want to delete the record", vbYesNo + vbQuestion, "alert") If res = vbYes Then adocom.Recordset.Delete adobill.Recordset.Delete MsgBox "Record is Deleted" adocom.Refresh adobill.Refresh Else adocom.Refresh adobill.Refresh End If End Sub Private Sub cmdlastfive_Click() DataGrid1.Visible = True Adodc1.RecordSource = "select top 5 billm,totalbill from cosbdes where=" & Val(txtShopn) 'Adodc1.Refresh DataGrid1.Refresh End Sub Private Sub cmdNew_Click() adocom.Recordset.AddNew adobill.Recordset.AddNew txtCname.SetFocus End Sub Private Sub cmdSave_Click() Dim res As String res = MsgBox("you want to save the record", vbYesNo + vbQuestion, "alert") If res = vbYes Then adocom.Recordset.Update adobill.Recordset.Fields("shop_no") = adocom.Recordset.Fields("shop_no") adobill.Recordset.Update MsgBox "Record is Updated" adocom.Refresh adobill.Refresh Else adocom.Recordset.CancelUpdate adobill.Recordset.CancelUpdate adocom.Refresh

Electricity Billing System

adobill.Refresh End If End Sub Private Sub comerfram_DragDrop(Source As Control, X As Single, Y As Single) End Sub Private Sub Form_Load() DataGrid1.Visible = False End Sub

9.4 Coding of Description Form: Private Sub cmdExit_Click() Unload Me End Sub Private Sub cmdOk_Click() If detailcb.ListIndex = 0 Then Text1.Text = "1.30 Rs" Text2.Text = "3.00 Rs" Text3.Text = "3.50 Rs" Text4.Text = "60.00 Rs" ElseIf detailcb.ListIndex = 1 Then Text1.Text = "4.00 Rs" Text2.Text = "4.25 Rs" Text3.Text = "4.50 Rs" Text4.Text = "100.00 Rs" End If End Sub Private Sub Form_Load() detailcb.AddItem ("DOMESTIC 0") detailcb.AddItem ("COMERCIAL 1") End Sub

9.5 Coding of Domestic Bill Calculation Form: Dim u, u1, u2 As Long Dim X, Y, z, p, d, f As String Private Sub cmd1exit_Click() Unload Me End Sub Private Sub cmdAdd_Click() adodesc.Recordset.AddNew

Electricity Billing System

bmtxt.SetFocus End Sub Private Sub cmdCancle_Click() bmtxt.Text = "" bdtxt.Text = "" tbtxt.Text = "" bntxt.Text = "" bntxt.Text = "" pdtxt.Text = "" txtbp.Text = "" End Sub Private Sub cmdclear_Click() txtfix.Text = "" txted.Text = "" txttotal.Text = "" txted.Text = "" txtsc.Text = "" txtec.Text = "" txtunit.Text = "" tbtxt.Text = "" txtunit.SetFocus End Sub Private Sub cmdDelete_Click() Dim res As String res = MsgBox("u w to delete the rec!", vbYesNo, "alert") If res = vbYes Then adodesc.Recordset.Delete MsgBox "record is deleted" adodesc.Refresh Else adodesc.Refresh End If End Sub Private Sub cmdExit_Click() bmtxt.SetFocus End Sub Private Sub cmdFilter_Click() Dim res res = InputBox("Enter The Criteria", "Filter") adodesc.RecordSource = "select * from Billdec where" & res End Sub

Electricity Billing System

Private Sub cmdFind_Click() Dim res As String res = InputBox("enter the criteria for a rec", "find") adodesc.Recordset.Find res, , adSearchForward, 1 End Sub Private Sub cmdOk_Click() If txtunit.Text = "" Then MsgBox "please enter unit" txtunit.Text = 0 End If txtfix.Text = "Rs 60.00" f = 60 u = CInt(txtunit.Text) If u 50 And u
View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF