Page 1

View with images and charts Patient Management System (PMS) 1.1 Introduction The objective of this part is to introduce the system that we want to develop .The problem of existing system and why this system should be automated. Doctors are most important part of our country. Doctors help us to take good health. They should be provided with consistent environment for take patient information. It provides an information system, which records necessary for a patient. This is known as Patient Information System (PMS). This system is used by the doctor or legal employee and contains all the relative information about patients and their dieses. This system ensures appropriate with proper security to the stored data within it. PMS helps patients by informing their previous/present dieses and treatment, diagnosis report, details advice and accounts relative information etc. 1.2 Case Study For the case study we choose Japan Bangladesh Friendship Hospital, Dhaka, Bangladesh. It has about 500 patients in a day. But, the details of patient are kept at the manual system in doctor chamber. This causes many problems. The registry doesn’t know any of the details of the patients and doesn’t have easy access to any details about patients. Sometimes it becomes very much time consuming. Watching those problems of this department we tried to develop new software named “Patient Management System (PMS)” which contains all the necessary information about the patient details, their disease description, treatment, diagnosis report details advice and accounts relative information etc. But have a another great problem that is most of the time patient lose their prescription and report which is very harmful for a patient to take treatment for next time. 1. 2.1 the problems in existing System Now a day, most of the doctors uses manual system that is they keep their record in the laser book. But this is too much analogues. If any person requests a query then the responsible employee can’t give him answer in a quick way. But this is not correct. Sometimes this manual would be damaged. For this reason, this scheme is not perfect or continues in this time. 1.2.2 Necessity of automation This is fully computer aided system. In this system, a person can quickly recover any data and query any question. All difficulties and damages are removed in this software. 1.2.3 Future Plan In future, this software may be developed for auto dieses detection and treatment with proper advice, developed for using through the internet. So that, any patient can easy access of this software for detect dieses and treatment etc. 1.2.4 Methodology

Software is a complex artifact created by human being. The entire complex being is produced in a step-by-step procedure, which is called methodology for that artifact. Therefore, methodology is needed for software in order to build it with consistency. Now as a wise system development follow a deliberate life cycle for precise & stepwise development of the software or system. We also follow Royce’s Software Development Life Cycle (SDLC). 1.2.5 Definition of SDLC A Software Development Life Cycle (SDLC) is an abstract description of the structured end methodological development and modification process applied to the main stages of producing and developing software. Request for a system Change Request

Feasibility Study (1)

Change Request Definition (8)

Requirement Definition (2)

System Specification(3)

Implementation (7) Testing (6)

System Design (4) Program Design & Coding (5)

Figure 1: Software Development Life Cycle Feasibility Study At first stage of SDLC we have to measure feasibility study of our proposed system that is system feasibility study of economics, implementation etc. Requirement Definition At this stage we have to develop system’s requirement by using well-known requirement engineering framework. RE involves three major frames, ----Requirement Analysis --Requirement Specification --Requirement Validation System Specification

In system specification our first concern is ERD (Entity Relationship Diagram), which shows entity with their attributes, relationship with entities involving one to one, one to many, many to one or many to many, assigning primary keys & perform normalizations to reduce data redundancy. System Design System Design accomplished by two ways; overall design and Detailed design. Overall design sets structure of shape of the software. “Structure Charts” might be used here as part of functional design strategy. Detailed design defines the processing that is carried out through the whole program. Stepwise refinement might be applied for our proposed system. Program Design & Coding SDLC model program design and coding occupies as little as 10% of project effort. Here we write the coding by using well-known programming language such as Object-Oriented language(C#). Testing Testing is one of the most important steps to develop a system. Testing is a process of finding errors. Testing can be implemented in our proposed by two ways, ---White Box Testing & --Black Box Testing. Implementation In SDLC model, this stage involves implementing our Patient Management System to any types of Information in the Japan Bangladesh Friendship Hospital, Dhaka at chamber of doctors & see how it works. Change Request Definition If any request comes after delivering the system then this stage defines the processing of development of the delivered system. This type of maintenance is very important. Now at conclusion when we have to develop our system (Patient Management System), we must follow SDLC that have been described above. 1.2.6 Necessity of using this model There are several process models available for the development of software. But we have considered Software Development Life Cycle as the appropriate framework in order to develop our software. The reasons are given below  Software Development Life Cycle (SDLC) is a complete cyclic process model. The software we need to develop must go throw the various stages of SDLC so that we can develop a more efficient and reliable software.

 Software Development Life Cycle (SDLC) has a starting point which has helped us to determine from where to start to develop our software.  Software Development Life Cycle (SDLC) has a system request and change request on maintenance. So does our software. For the maintenance of the software and to make it more reliable we are ready to accept user request.  Software Development Life Cycle (SDLC) is a linear sequential process model and triggered. Background 2.1 About Process Model Process is an activity, which operates on an object and changes its state. Model is the graphical representation of an object. So, a process model shows the activities of software graphically. 2.2 Necessity Process Model We need process model because process is important than product (software). If the process is good, the product also is good. 2.3 A particular Process Model for Patient Management System Software Development Life Cycle (SDLC) is a general cycle to develop software. But, in this software we use a specific Process Model that is “Throw away Process Model” Throw Away Process Model Prototyping loop developed Prototype Specification

Specification derived from Prototype Software Specification


Standard Process Design


Test Test

Review Prototype

Figure 2.1 Throw Away Prototyping Process Model


We choose Throw Away Prototyping Process Model, because of its following advantages: 1) Requirement become clear as customer actually use the system. a) Misunderstandings are clarified. b) Missing functions are clarified. c) Poor interface can be refined. d) Missing requirement can be identified. 2) Proper working system is produced, although it is limited in functionality and performance. 3) Prototype becomes Specification. Requirements 3.1 Functional requirements Functional requirements for a system describe the functionality or services that the system is expected to provide. They depend on the type of software, which is being developed, the expected users of the software and the type of system, which is being developed. Functional requirements for a software system may be expressed in a number of different ways. Here are a number of functional requirements for “Patient Management System”: 1) The user shall be able to search either all of the initial set of databases or select a subset from it. 2) The system shall provide appropriate viewers for the user to read documents. 3) Every order shall be allocated a unique identifier. 3.2 Nonfunctional Requirements Non-functional requirements are used to define system properties and constraints. These types of requirements arise through user needs because of external factors that may control software environment. For the “Patient Management System”, the non-functional requirements are:  How efficiently and reliably, we can use our system.  How quickly the system delivered services by maintaining standard.  Security, privacy and safety.  User Friendly 3.3 Requirement Engineering Requirement engineering is that activity transforms the needs and wishes of customers and potential users of computerized systems, usually incomplete, and expressed in informal terms, into complete, precise, and consistent, preferably written in formal notation. Needs and Wishes 3.4 Requirement Engineering Process

Complete Precise Consistent Con

To develop particular software, everyone should follow all the process of requirement engineering. We can define requirement engineering as follows: Requirement Engineering is the systematic process of developing requirements through an iterative co-operative process of analyzing the problem (Requirement analysis), documenting the observations in a variety of representation formats (Requirement specification) and checking (Validation) the accuracy of the understanding gained. User feedback


Models to be validated by user

User Requirements Requirement Specifications

Requirement models

Knowledge Requirement Modeling

Elicitatio n

Request More knowledge

Validatio Validation n results

Domain Knowledge

Domain Knowledge

Problem Domain

Figure 3.1 Requirement Engineering Process There are three process considered in Requirement engineering. Those are: i) Requirement Analysis / Elicitation, ii) Requirement Validation, iii) Requirement Specification.

3.4.1 Requirement Analysis Requirement Analysis is the process of acquiring (eliciting) all the relevant knowledge needed to produce a requirement model of a problem domain. It is an iterative process, which involves domain understanding, requirement collection, classification, structuring, conflict resolution, prioritization and validation. We can diagrammatically represent requirement analysis process as the below figure: Requirement specifications Requirement validation

Process entry

Domain understanding


Requirement collection

Conflict resolution

Classification Figure 3.1: Requirement Analysis Process Model Requirement Analysis using VORD method We are applying here VORD method. Here are four phases in the VORD method.

Viewpoint identification Discovering Viewpoints Those are • • • •

Viewpoint Structuring Grouping them into into a hierarchy

Viewpoint documentation

Viewpoint system mapping

Refinement of the description of the viewpoints And services identified

Viewpoint Identification Viewpoint structuring Viewpoint documentation Viewpoint System mapping

► Viewpoint Identification Viewpoint Identification, which involves discovering viewpoints that receive system services and identifying the specific services provided to each viewpoint. ► Viewpoint structuring Viewpoint structuring, which involves into a hierarchy. Common services are provided at higher levels in the hierarchy and are inherited by lower – level viewpoints. ► Viewpoint Documentation

Viewpoint documentation, which involves refining the description of the identified viewpoints and services. ► Viewpoint – system mapping Viewpoint – system mapping, which involves identifying objects in an object – oriented design using service information, which is encapsulated in viewpoints. Viewpoint Identification using Brainstorming The approach used to identify the viewpoint is brainstorming, which is given in the below:

Patient Informati on

Valid User ID

Hospital/ Chamber Crashing OS

Informati onal Security Dieses

Friendly Behaviors


Registrati on ID

Select Service

Doctors Events Of Doctors




Electricity Failure

Invalid ID

Figure 3.2: Viewpoint Identification using Brainstorming

Don’t Take enough Time

Key Factors: REPRESENTS “Viewpoint”

REPRESENTS “Non – Functional Requirement “


REPRESENTS “Control Event”


REPRESENTS “Exception” View Points    

Patient Dieses Treatment Accounts Service  Patient Information  Patient Treatments  Accounts Data input  Patient ID number, Patient Name, Age, Address, Referrer  Treatment, Advice  Accounts (Visit Fee) Exception  Security of user information  Invalid ID  Consistency in staff scheduling Non-functional requirements  Friendly Behaviour from employees and patients

 Crashing OS  Electricity Failure Control event  Valid user ID  Select Service PMS viewpoints and their service templates Template For Service – 1:

Reference: Patient Attribute: ID, Name, Sex, Address, Phone No. Events: Start Checking ID Select Service Supply Information Required End Services: Treatment

Reference: Treatment Rationale: To increase patient service and reduce paperwork. Specification: User first choose the patient Information button and then enter the ID of the patient. Then the information is supplied to the user. Non – Functional: Getting the accurate Information about patient. Scenarios Scenario can be particularly useful adding detail to an outline requirement description. At its most general, a scenario may include: 1) A system state description at the beginning of the scenario. 2) A description of the normal flow of events in the scenario. 3) A description of what can go wrong and how this is handled. 4) Information about other activities, which might be going on the same time. 5) A description of the state of the system after completion of the scenario. Event scenario Event Scenario is used in VORD method to document the system behavior when presented with specific events. Event scenarios for “Student Information System”, is given below: Valid ID Patient ID

User ID

Request Patient ID

Time out Invalid ID (no reply)

Request again

Figure 3.3: Event scenario

Valid data(OK)

Validate Patient Check ID no.

Select Service

Incorrect ID no. Re-enter ID no. Incorrect ID no. Re-enter ID

3.4.2 Requirement Specification Requirement Specification can be viewed as a contract between user and software developer which defines the desired behavior of the software artifacts without showing hoe such functionality is going too achieved. Requirement definition  Requirement Definition associated with a problem in a formal way Reference: Information about patients Definition: This service holds all the patients details. Action/Process: Request patient ID, enter the ID into system, shows the information. Rationale: This helps to know patient details perfectly. Reference: Requirement analysis service template-1 Reference:

How to Admit Definition: The patient who seeks to admit gets all the information from this service. Action/Process: Asking for the process to get admitted Rationale: This helps doctors about the process of the treatment. Requirement Specification (using PDL) Procedure PMS ID Patient_ID;

Service Avail_Service; Password, Valid_ID_No; Begin Loop Get_ID (Password, Valid_ID_No); If Valid_ ID_No & Password then Get_Details (ID); Get_Service (Service); While a Service is selected Loop Deliver_Service (Service); Get_Service (Service); End While; Else Print ("Error Message"); End if; End Loop End procedure PMS 3.4.3 Requirement Validation The identified requirements are checked to discover if they are complete and consistent in accordance with that subscriber really want from the system. Different types of check in validation During the requirement validation process, different types of checks should be carried out. These checks include: 1) Validity checks 2) Consistency checks 3) Completeness checks 4) Realism checks 5) Verifiability For “Patient Management System”, the above validities were checked. Requirement Validation techniques There are a number of requirements validation techniques, which can be used in conjunction or individually. The validation techniques are: 1) Requirement reviews 2) Prototyping 3) Test-case generation 4) Automated Consistency For “Patient Management System”, we prefer Prototyping requirement validation technique. Design & System Specification 4.1 Software Specification

There are three levels of software specification, which may be developed. These are: 1) User requirement 2) System requirement 3) A software design specification The user requirements are the most abstract specification and the software design specification is the most detailed. 4.2 Formal Software Specification Formal Software Specification can be expressed in a language whose vocabulary, syntax and semantics are formally defined. Specification language cannot be based on natural language but on mathematics. In general, formal mathematical specification lie somewhere between system requirement and software design specifications. They don’t include implementation detail but should present a complete mathematical model of the system. 4.3 Formal Specification in the Software process The following figure shows the stages of software specification and its interface with the design process: System Requirement Specification

Formal Specification

High-level Design

User Requirement Definition System Modeling

Architectural Design

Figure 4.1 Formal Specification in the Software process 4.4 Formal Specification language There are two approaches to formal specification that have been used to write detailed specifications for non-trivial software system. These are: 1) An algebraic approach where the system is described in terms of operations and their relationships. 2) A model based approach where a model of the system is build using mathematical constructs such as sets and sequence and the system operations are defined by how they modify the system state.

Overall Design 4.5 A general Model of software design process Design is the process of translating between the specifications of what the system must do in to a specification of how the system will accomplish it. Software engineer conduct each of the design task. In the design process for Registration Management System, we have to translate the system’s requirement specification into a design that can be implemented by using many tools and techniques by the programmer. A general Model of software design process is shown in below figure:

Requirement Specification

Architectural Design

Abstract Specification

System Architecture

Interface Specification

Component Design

Interface Design



Software Specification

Data structure Design

Data structure Specification

Algorithm Design Algorithm Specification

Figure 4.2: A general Model of software design process Here, Architecture Design specifies the set of components that make up the program. Interface Design specifies the way in which the component interacts. The Component Design specifies the responsibilities that are allowed to the components. Data Structure Design specifies the data structure used in the program are designed in detail and specified. Algorithm Design specifies the algorithm that allows the components to fulfill their responsibilities must be identified. 4.6 Structure Analysis The aim of structured analysis is to transform the textural description of a problem into graphical model.



Data flow 



Figure 4.3: Context Diagram

External  Entity




4.7 Entity Relationship Diagram (ERD) The Entity Relationship Diagram for “Patient Management System” is drawn below: Figure 4.4 Entity Relationship Diagram

Gardian Name


P_Addres s




Refered By



P_Nam e

Patient Information


Doctor Name

Previous Dieses

Sub Totak

Patient Treatment


Paid Amount

amount Discou






Total Taka


Patient Treatment

PMS Previous Dieses

Here, Data Flow Represents entity Represents attribute Represents relationship Represents link to the attributes and relationship. 4.8 Data Flow diagram (DFD) Data flow Diagram (DFD) is concerned with understanding the processing within an organization and the relationship between those processes. DFD graphically illustrates movement of data between external entities and the processes and data stores within a system. DFD for “Patent Management System� will be as follows: DFD For Level 1

Giving Data

Data Entry 1.1

Valid Data (ID)

Processin g Patient Details Transmitting 1.3 Information Displaying Information 1.5

Informatio n Of Patient 1.2 Request Patient Sending Details Treatment Transmitting Information Request Treatment Sending Name

Figure 4.5 DFD Level 1

Processin g Treatment Details 1.3 Asking Sending Treatment

Retrieving Treatment 1.4

4.9 Afferent Data Flow

Incoming data flows Giving Data

Entering Data

Valid Data (ID)


Informatio n Of Patient 1.2

Requesting Type

Processin g Personal Details 1.3

Request Patient Sending Details

Transmitting Information Displaying Information 1.5

Asking Type

Dieses Transmitting Information Request Treatment Sending Name

Figure 4.6 Afferent Data Flow

Processin g Dieses Details 1.3 Asking Sending Courses

Retrieving Dieses1.4

4.10 Efferent Data Flow Outgoing data flows

Processi ng

Request Patient Sending Details

Personal Details 3 Transmitting Information Transmitting Information Displaying Information 5

Request Showing

Figure 4.7 Efferent Data Flow


Processin g treatment Details 3

4.11 Structured Chart

PMS Valid Data ACAD_ID

Entering Data

Processing Dieses Details


Rece_Cou_info Print


Retrieving Dieses

Personal Details

Displaying Information

ACAD_Info P_File

Dieses Information

Sending request to file


Deliver information

p_File Re_Co

Sending request to file

Receiving Dieses *

Delivering Details

Figure 4.8 Structured Charts In the above figure we describe the “Structure chart” notation for our proposed Patient Management System. The figure --Represents Modules that mean where we write code.

Represents as like as Library Function. Represents Data couples.

4.12 Detailed Design Detailed design defines the processing that is carried out in the modules. It specifies “the how” for each module in the design. We can use “stepwise Refinement” strategy to develop detailed design for “Patient Management System”. In stepwise refinement we start at the high level & refine it progressively down into sets of lower level statements. This can be done

using a number of notations and techniques. In the most cases, we prefer pseudocode because- it is flexible and is familiar to programming language. There is well known techniques to develop the detailed design for any wise system. This is the JSP (Jackson Structured Programming). It is a methodical approach proposed by “structured methods” which are sets of notations and guidelines for software design. 4.12.1 Jackson Structured Programming PMS Process’s sequences Entering Data Processing Chamber Details Processing Personal Details Retrieving Dieses Displaying Information PMS end Information of Patients selects like Personal Life Personal Life record Information of patients or like Personal Personal record Information of patients end Retrieving Dieses Receiving Dieses Symptom Retrieving Dieses end 4.13 Data Dictionary Data Dictionary is known as Meta data that is data about data. Data Name: Doctor Name Definition: The doctor who want to gather information from patient. Details: Data Type: Char First Name + Middle Name + Last Name. Data Name: Patient Information Definition: Total Information of the patients. Details: Data Type: Char, Integer; P_Name, ID_No,Sex, Age, Address, Ph_no Data Name: Treatment Information Definition: The doctor who identify the dieses & treatment. Details: Data Type: Char, P_ame, P_ID, Medicine, Advice. Data Name: Accounts Information

Definition: Payment of visit fee, Dues, Advance. Details: Data Type: Char, integer, P_Name, P_ID, Total bill, Payment, Dues, Advance, balance. 4.14 User Interface Design process While developing the Student Information System, we use the following User Design Process.

Analyze and understand user activities

Produced paper based design prototype

Design prototype

Evaluate design with end users

Produce dynamic design prototype

Evaluate prototype


Evaluate design with end users

Implement final user interface

Figure 4.9 User Interface Design Process 4.14.1 User Interface Design principles The following “User Interface Design principles� were considered while developing the software: a) User Familiarity: b) Consistency c) Minimal Surprise d) Recoverability e) User guidance f) User diversity 4.15 Some Snapshots of PMS Main Window

Figure 4.10 Log in window

Figure 4.11 Data Entry Form

Figure 4.11 Data Entry Form

Figure 4.12 Data Report Testing 5.1 Testing Testing is a process of executing a program with the intent of finding errors  A good test case is one that has a high probability of finding an as-yet undiscovered error  A successful test is one that uncovers an as-yet undiscovered error  Testing cannot show the absence of defects, it can only show that software errors are present To ensure software quality we must need to test software. To accomplish testing for our software we have considered White Box Testing for Search patient module in this regard. We can diagrammatically show different stags of a testing process in below: Test a module’s control structure uses white box techniques carried out by developer Unit testing

Verification of system and overall program structure uses black box and limited white box Integration testing

Validation testing, does it meet the user’s expectation, black box test

Validation test Final operational test System test

Figure 5.1 the testing process 5.2 Classification of Testing There are two basic type of testing. These are: 1) Static testing 2) Dynamic testing 5.2.1 Static testing Static testing is related with inspecting the code. For this software, all the codes are reviewed several times. 5.2.2 Dynamic Testing There are two types of dynamic testing. These are: a) White box testing b) Black box testing box testing In this type of testing all the lines are tested by executing the program. For “Patient Management System�, executing the program all the lines is tested. To perform white box testing, basis set testing is applied. 5.3 Basis set testing Basis set testing is a testing method that is used to find the logical path of a module. A module is given below to Sell Products: stmt.executeQuery ("select P_ID from Sum where P_ID = '"+jTextField1.getText()+"'"); if(! //1 { JOptionPane.showMessageDialog (null, "ID does not match "," Error", JOptionPane.ERROR_MESSAGE); //2 Return ; } //3 else stmt.execute ("delete * from Sum1 where St_ID = '"+jTextField1.getText()+"'"); //4

}//5 5.4 Flow Graph We can draw flow graph for the module patient Register in below:







The distinct paths Path-1 1











5.5 Cyclomatic Complexity Cyclometric complexity is the number of paths used in the graph: Cyclometric complexity is calculated by the following equation: V (G) = E – N + 2 =5–5+2 =2

Where, V (G) = Cyclometric complexity of the graph. E = Number of Edges. N = Number of nodes.

5.6 Test Log • •

This is a log that records the tests applied and the results of each test For a module this may look like a table

Conditions User-Name=1 Password= 01

Expected results False

Actual results False

Comment Ignore

User-Name =A Password= 1




Application 6.1 Problem Domain We apply this system in the Japan Bangladesh Friendship Hospital, Dhaka where every patient will get their personal and dieses information using our System. It will be connected through network. 6.2 How it Works Admin login: At first user open the software and gives His / Her Name and password. If invalid id or password be given then it cannot be access. And If valid id or password be given then it can be access. Fig: Login page

Figure 6.1 Log in Form Service There are three types are available. 1. Patient Information 2. Treatment Information 3. Accounts Information

Figure 6.1 Code Form Discussion and conclusions

7.1 Discussion Maintenance “Maintenance is the general process of changing a system after it has been delivered.” Our proposed Patient Management System is applied to the Japan Bangladesh Friendship Hospital. Necessity of maintenance Though software does not ware out, it needs maintenance for the following reasons: 1) It was delivered bugs. The bugs may be coding error, design error or analysis error. 2) The environment in which the software operates may change. For example: the operating system may change or hardware platform may change. 3) The customer requirement may change. For example: the software requires new features. Therefore, software needs maintenance. Several types of maintenance There are three kinds of maintenance. These are: 1) Corrective Maintenance 2) Adaptive Maintenance 3) Perfective Maintenance Corrective Maintenance When bugs appear in the software, these bugs need to be correct. The process of removing bugs is corrective maintenance. Adaptive Maintenance When the environment of the software changes, the software must adapt with its environment. The process of adapting with environment is adapting maintenance. Perfective Maintenance When the customer requirement changes, the software must fulfill its customer requirement. To fulfill customer requirement is perfective maintenance For “Patient Management System”, any one of the three maintenance will be carried out if necessary. Iterative Development of Maintenance

Ideally maintenance can be thought of as an iteration through a standard software development.

Change Request

Change Analysis

Update Requests

Software Development

Standard Development Process

Figure7.1. Iterative Development of Maintenance In “Patient Management System” We use this kind of Maintenance. Maintenance as Fault Repair In practical situation, the maintenance activity has to take place urgently to respond to customer problems. So, when problem occurs, we prefer “Maintenance as Fault Repair” process for “Patient Management System”. The process is shown below: Change request

Analyze source code

Modify source code

Derived repaired system

Fig: Maintenance as Fault Repair Necessity for documentation For the following reasons, software documentation is needed: 1) Software has no physical form. To give software physical form, Documentation is necessary. 1) Software is abstract because they are intangible. We can tangible software by documenting it.

Intangible software Documentation Tangible software

Textual Documentation We can textually document the software by writing comment in the code. Textual documentation is done when the developer writes the code. Documentation providing manuals We can document software by providing manuals. There are two types’ manuals. These are: 1) Developer manual 2) User manual Developer manual The manual, which is useful for the developer, is called developers manual. User manual As we’re new developer and we have not yet develop any big project such like that, we can’t fulfill user manual completely. But we ‘are trying to develop this. And we’ll develop this perfectly in the next version of this software. System Requirements Any person who want to run “Patient Management System” in his/her computer then he/she must have the following minimum software and hardware requirements. Hardware Requirements ** Processor: 1.6 MHz ** RAM: 256 MB ** Hard Disk: 500 MB free memory Software Requirements ** Object-Oriented Programming Language (C#) ** MS SQL Server ** Seagate Crystal Report ** .net frame work 3.0 7.2 Future Works In future, this software may be developed for auto dieses detection and treatment with proper advice, developed for using through the internet. So that, any patient can easy access of this software for detect dieses and treatment etc. 7.3 Conclusion We have tried as best as possible to give them a best solution with our capability, industry and patience. In this solution, some limitations may have. But we have tried to overcome the limitations as per as possible. At last, we hope that the proposed system will run in better way

with high performance and the system users will satisfy to run this system, which is more comfortable than their existing system. References [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]

Microsoft Visual Studio 2008 Downloaded=10443 Download ID=10443&wa=wsignin1.0

Appendix-A Project Code for Simulation Login Form

This is the Login Form. The Login form is important from the security of the Project and it is the main form the project. It is ensure that the system is protected against any unauthorized person. This form only use for administrator and he has full control over the project and the Information Tracking System can only collect information. The administrator can change password if they wish to. 1.Code For Patiement Management Syatem using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Data.SqlClient; using PatientManagement.DAL; namespace PatientManagement.Forms { public partial class frmSecurity : Form { public frmSecurity() { InitializeComponent(); }

private void button2_Click(object sender, EventArgs e) { string sql; sql="update TBL_Security set ID='" +txtEnterId.Text.Trim() +"',Password='"+txtEnterPassword.Text.Trim()+"'"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("Data Edited Successfully"); Conn.Close();

} private void btnDelete_Click(object sender, EventArgs e) { string sql; sql="delete from TBL_Security where ID='"+txtEnterId.Text.Trim()+"'"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("Data Deleted Successfully"); this.txtEnterId.Text=""; this.txtEnterPassword.Text = ""; Conn.Close(); } private void btnClose_Click(object sender, EventArgs e) { this.Dispose(); } private void btnSave_Click(object sender, EventArgs e) {

string sql; sql = "INSERT INTO TBL_Security (ID, Password ) " + " values('" + this.txtEnterId.Text.Trim() + "','" + this.txtEnterPassword.Text.Trim() + "' )";

SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("ID & Password Created Successfully"); Conn.Close();

} } } using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Data.SqlClient; using PatientManagement.DAL; using PatientManagement.Forms; using System.IO; using System.Drawing.Imaging; using PatientManagement.DAL; namespace PatientManagement { public partial class frmPatientInformation : Form { public frmPatientInformation() { InitializeComponent(); } private void label11_Click(object sender, EventArgs e) { } private void FillCategoryCode() { Cursor = Cursors.WaitCursor; // this.cmbCategory.Items.Clear(); string SQL = "SELECT CatID, CatName FROM CategoryInfo order by CatName"; SqlConnection Conn = new SqlConnection(DAL.DBAccess.strConnection); SqlCommand Comm = new SqlCommand(SQL, Conn); try { Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); while (thisReader.Read())

{ // this.cmbCategory.Items.Add(thisReader.GetValue(1).ToString().Trim() + "~" + thisReader.GetValue(0).ToString().Trim()); } // this.cmbCategory.SelectedIndex = 0; } catch (Exception exp) { MessageBox.Show(this, exp.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } finally { Conn.Close(); } Cursor = Cursors.Default; } private void groupBoxPatientInformation_Enter(object sender, EventArgs e) { this.btnInsert.Focus(); } private void button2_Click(object sender, EventArgs e) { } private void button3_Click(object sender, EventArgs e) { } private void txtPatientId_TextChanged(object sender, EventArgs e) { //lblPatiId.ForeColor = Color.Red; lblPatientID.ForeColor = Color.Red; Image_Show(); } private void Image_Show() { this.Cursor = Cursors.WaitCursor; pictureBox1.Image = null; string SQL = "Select Pict from TBL_Patient_Information where Patient_id = '" + this.txtPatientId.Text.Trim() + "'";

SqlConnection SqlConnection(PatientManagement.DAL.DBAccess.strConnection); SqlCommand Comm = new SqlCommand(SQL, Conn);




try { Conn.Open(); SqlDataReader dr = Comm.ExecuteReader(); if (dr.Read()) { if (dr.IsDBNull(0) == true) { pictureBox1.Image = null; this.Cursor = Cursors.Default; return; } long length1; length1 = dr.GetBytes(0, 0, null, 0, int.MaxValue); /*if (length1 == 0) { // pictureBox1.Image = Image.FromHbitmap(HandleDestroyed); return; }*/ byte[] byteBLOB = new byte[length1 - 1]; dr.GetBytes(0, 0, byteBLOB, 0, byteBLOB.Length); MemoryStream stream = new MemoryStream(byteBLOB); pictureBox1.Image = Image.FromStream(stream);

} //else // pictureBox1.Image = null; dr.Close(); Conn.Close(); } catch (Exception ex) { //throw ex; MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); }

this.Cursor = Cursors.Default; } private void txtPatientId_Enter(object sender, EventArgs e) { } private void txtPatientId_Leave(object sender, EventArgs e) { lblPatientID.ForeColor = Color.Black; txtPatientId.BackColor = Color.White; } private void txtPatientName_Leave(object sender, EventArgs e) { lblPatientName.ForeColor = Color.Black; txtPatientName.BackColor = Color.White; } private void txtPatientName_Enter(object sender, EventArgs e) { lblPatientName.ForeColor = Color.Red; txtPatientName.BackColor = Color.AntiqueWhite; } private void btnClose_Click(object sender, EventArgs e) { this.Dispose(); //frmPatientInformation f = new frmPatientInformation(); frmPatentTreatment f = new frmPatentTreatment(); //f.MdiParent = this; f.Show(); } private void txtPatientAge_Leave(object sender, EventArgs e) { txtPatientAge.BackColor = Color.White; lblPatientAge.ForeColor = Color.Black; } private void txtPatientAge_Enter(object sender, EventArgs e) { txtPatientAge.BackColor = Color.AntiqueWhite; lblPatientAge.ForeColor = Color.Red; }

private void txtPatientName_TextChanged(object sender, EventArgs e) { } private void txtGardianName_TextChanged(object sender, EventArgs e) { } private void txtGardianName_Enter(object sender, EventArgs e) { lblGardianName.ForeColor = Color.Red; txtGardianName.BackColor = Color.AntiqueWhite; } private void txtGardianName_Leave(object sender, EventArgs e) { txtGardianName.BackColor = Color.White; lblGardianName.ForeColor = Color.Black; } private void txtPatientAddress_Enter(object sender, EventArgs e) { txtPatientAddress.BackColor = Color.AntiqueWhite; lblPatientAddress.ForeColor = Color.Red; } private void txtPatientAddress_Leave(object sender, EventArgs e) { txtPatientAddress.BackColor = Color.White; lblPatientAddress.ForeColor = Color.Black; } private void txtPhoneNo_Enter(object sender, EventArgs e) { txtPhoneNo.BackColor = Color.AntiqueWhite; lblPhoneNo.ForeColor = Color.Red; } private void txtPhoneNo_Leave(object sender, EventArgs e) { txtPhoneNo.BackColor = Color.White; lblPhoneNo.ForeColor = Color.Black; } private void txtPreviousDieses_Enter(object sender, EventArgs e) { txtPreviousDieses.BackColor = Color.AntiqueWhite; lblPreviousDieses.ForeColor = Color.Red;

} private void txtPreviousDieses_Leave(object sender, EventArgs e) { txtPreviousDieses.BackColor = Color.White; lblPreviousDieses.ForeColor = Color.Black; } private void txtTreatmentNote_Enter(object sender, EventArgs e) { txtTreatmentNote.BackColor = Color.AntiqueWhite; lblTreatmentNote.ForeColor = Color.Red; } private void txtTreatmentNote_Leave(object sender, EventArgs e) { txtTreatmentNote.BackColor = Color.White; lblTreatmentNote.ForeColor = Color.Black; } private void txtReferedBy_Enter(object sender, EventArgs e) { txtReferedBy.BackColor = Color.AntiqueWhite; lblReferedBY.ForeColor = Color.Red; } private void txtReferedBy_Leave(object sender, EventArgs e) { txtReferedBy.BackColor = Color.White; lblReferedBY.ForeColor = Color.Black; } private void txtPatientId_MouseMove(object sender, MouseEventArgs { //txtPatientId.BackColor = Color.Blue; } private void txtPatientId_MouseLeave(object sender, EventArgs e) { //txtPatientId.BackColor = Color.Yellow; } private void btnMain_MouseHover(object sender, EventArgs e) { //btnMain.BackColor = Color.Red; } private void btnMain_MouseLeave(object sender, EventArgs e) { //btnMain.BackColor = Color.Cyan;


} private void comboBox1_Enter(object sender, EventArgs e) { cmbBoxSex.BackColor = Color.AntiqueWhite; lblSex.ForeColor = Color.Red; } private void cmbBoxSex_Leave(object sender, EventArgs e) { cmbBoxSex.BackColor = Color.White; lblSex.ForeColor = Color.Black; } private void btnMain_Click(object sender, EventArgs e) { forms.frmMain f = new PatientManagement.forms.frmMain(); f.MdiParent = this; f.Show(); } private void btnTreatment_Click(object sender, EventArgs e) { this.Dispose(); frmPatentTreatment f = new frmPatentTreatment(); // f.MdiParent = this; f.Show(); } private void btnAccounts_Click(object sender, EventArgs e) { this.Dispose(); forms.frmPatientAcc f = new PatientManagement.forms.frmPatientAcc(); // f.MdiParent = this; f.Show(); } private void btnSave_Click(object sender, EventArgs e) { if (txtPatientName.Text.Trim() == "") { MessageBox.Show("Name required"); txtPatientName.Focus(); return; } string sql;

sql = "INSERT INTO TBL_Patient_Information (Patient_id, Patient_name, Patient_Age, Patient_Gardian, Sex, Patient_Address, [Phone_ No], Previous_Dieses, Treatment_Note, Refered_By) values('" + this.txtPatientId.Text.Trim() + "','" + this.txtPatientName.Text.Trim() + "','" + this.txtPatientAge.Text.Trim() + "','" + this.txtGardianName.Text.Trim() + "','" + this.cmbBoxSex.Text.Trim() + "','" + this.txtPatientAddress.Text.Trim() + "','" + this.txtPhoneNo.Text.Trim() + "','" + this.txtPreviousDieses.Text.Trim() + "','" + this.txtTreatmentNote.Text.Trim() + "','" + this.txtReferedBy.Text.Trim() + "')";

SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("Data Saved Successfully"); Conn.Close(); FillDGVPatient(); } private void btnRefresh_Click(object sender, EventArgs e) { this.txtPatientId.Text = ""; this.txtPatientName.Text = ""; this.txtPatientAge.Text = ""; this.txtPatientAddress.Text = ""; this.txtGardianName.Text = ""; this.txtPhoneNo.Text = ""; this.txtPreviousDieses.Text = ""; this.txtTreatmentNote.Text = ""; this.txtReferedBy.Text = "";

} private void button1_Click(object sender, EventArgs e) { string str = DBAccess.s1(); MessageBox.Show(str); string str2 = DBAccess.Get_Description(txtPatientName.Text.Trim()); MessageBox.Show(str2); }

private void frmPatientInformation_Load(object sender, EventArgs e) {FillDGVPatient(); } private void FillDGVPatient() { string SQL; SQL = " select * from TBL_Patient_Information order by AutoSl Desc"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection ); Conn.Open(); SqlDataAdapter da = new SqlDataAdapter(SQL, Conn); DataSet ds = new DataSet(); da.Fill(ds, "TBL_Patient_Information"); dgvPatientInfo.DataSource = ds.Tables["TBL_Patient_Information"]; } private void filldgvTreatment() { string sql; sql = "SELECT * FROM TBL_Patient_Treatment order by AutoSl Desc"; SqlConnection conn = new SqlConnection(DBAccess.strConnection); conn.Open(); SqlDataAdapter da = new SqlDataAdapter(sql, conn); DataSet ds = new DataSet(); da.Fill(ds, "TBL_Patient_Treatment"); //dgvTreatment.datasource = ds.Tables["TBL_Patient_Treatment"]; dgvTreatment.DataSource = ds.Tables["TBL_Patient_Treatment"]; } private void btnInsert_Click(object sender, EventArgs e) { FindMaxPID(); this.txtPatientName.Focus(); } private void FindMaxPID() { string SQL = "SELECT isnull(Max(Patient_id),1000)+1 from TBL_Patient_Information"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(SQL, Conn); try { Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); if (thisReader.Read()) { this.txtPatientId.Text = Convert.ToString(thisReader.GetValue(0));

} } catch (Exception ex) { MessageBox.Show(this, ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } finally { Conn.Close(); } } private void btnReport_Click(object sender, EventArgs e) { if (txtPatientId.Text.Trim() == "") { MessageBox.Show("Please insert patient ID"); return; } this.Cursor = Cursors.WaitCursor; string SQL = " SELECT * FROM TBL_Patient_Information where patient_id='"+txtPatientId.Text+"' "; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); DataSet ds = new DataSet(); try { Conn.Open(); SqlDataAdapter da = new SqlDataAdapter(SQL, Conn); da.Fill(ds, "TBL_Patient_Information"); } catch (Exception ex) { throw ex; } frmReport rptviewer = new frmReport(); rptviewer.ReportPath = Common.ReportLocation + "rptPatientInfo.rpt"; rptviewer.Reportds = ds; rptviewer.Show(this); this.Cursor = Cursors.Default; } private DataGridViewCellEventArgs e)




{ this.txtPatientId.Text = dgvPatientInfo.CurrentRow.Cells[0].Value.ToString(); this.txtPatientName.Text = dgvPatientInfo.CurrentRow.Cells[1].Value.ToString(); } private void btnEdit_Click(object sender, EventArgs e) { string sql; sql = "update TBL_Patient_Information set Patient_name='" + txtPatientName.Text.Trim() + "',Patient_Age='" + this.txtPatientAge.Text.Trim() + "' where Patient_id='"+txtPatientId.Text.Trim()+"'"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("Data Edited Successfully"); Conn.Close(); FillDGVPatient(); } private void btnDelete_Click(object sender, EventArgs e) { if(txtPatientId.Text.Trim()=="") { MessageBox.Show("Please Insert Patient ID"); return; } string sql; sql = "DELETE FROM TBL_Patient_Information where Patient_id='" + txtPatientId.Text.Trim() + "'"; //where Patient_id='"+txtPatientId.Text.Trim()+"'"; SqlConnection Conn = new SqlConnection(DBAccess.strConnection); SqlCommand Comm = new SqlCommand(sql, Conn); Conn.Open(); SqlDataReader thisReader = Comm.ExecuteReader(); thisReader.Read(); MessageBox.Show("Data Deleted Successfully");

Conn.Close(); FillDGVPatient(); }

private void btnInsert_Enter(object sender, EventArgs e) { btnInsert.BackColor = Color.SkyBlue; } private void btnSave_Enter(object sender, EventArgs e) { btnSave.BackColor = Color.SkyBlue; } private void btnEdit_Enter(object sender, EventArgs e) { btnEdit.BackColor = Color.SkyBlue; } private void btnDelete_Enter(object sender, EventArgs e) { btnDelete.BackColor = Color.SkyBlue; } private void btnRefresh_Enter(object sender, EventArgs e) { btnRefresh.BackColor = Color.SkyBlue; } private void btnSearch_Enter(object sender, EventArgs e) { btnSearch.BackColor = Color.SkyBlue; } private void btnReport_Enter(object sender, EventArgs e) { btnReport.BackColor = Color.SkyBlue; } private void btnClose_Enter(object sender, EventArgs e) { btnClose.BackColor = Color.SkyBlue;

} private void btnInsert_Leave(object sender, EventArgs e) { btnInsert.BackColor = Color.White; } private void btnSave_Leave(object sender, EventArgs e) { btnSave.BackColor = Color.White; } private void btnEdit_Leave(object sender, EventArgs e) { btnEdit.BackColor = Color.White; } private void btnDelete_Leave(object sender, EventArgs e) { btnDelete.BackColor = Color.White; } private void btnRefresh_Leave(object sender, EventArgs e) { btnRefresh.BackColor = Color.White; } private void btnSearch_Leave(object sender, EventArgs e) { btnSearch.BackColor = Color.White; } private void btnReport_Leave(object sender, EventArgs e) { btnReport.BackColor = Color.White; } private void btnClose_Leave(object sender, EventArgs e) { btnClose.BackColor = Color.White; } private void btnLoadimage_Click(object sender, EventArgs e)

{ { string strFileName; if (openFileDialog1.ShowDialog() == DialogResult.OK) { strFileName = openFileDialog1.FileName; try { pictureBox1.Image = Image.FromFile(strFileName); } catch (Exception ex) { MessageBox.Show(ex.Message, "Image Load Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } } } } private void btnSaveImage_Click(object sender, EventArgs e) { this.updateImage(); } private void updateImage() { SqlConnection sqlConn = new SqlConnection(DAL.DBAccess.strConnection); SqlCommand sqlComm = sqlConn.CreateCommand(); sqlComm.CommandText = "Update TBL_Patient_Information set Pict=@pict where Patient_Id ='" + Convert.ToString(this.txtPatientId.Text.Trim()) + "'"; try { sqlConn.Open(); //create Memory stream MemoryStream stream = new MemoryStream(); pictureBox1.Image.Save(stream, ImageFormat.Jpeg); //copy data from memorystream to byte array byte[] byteBLOB = new byte[stream.Length - 1]; stream.Position = 0; stream.Read(byteBLOB, 0, byteBLOB.Length);

//create parameter Object sqlComm.Parameters.Add("@pict", SqlDbType.VarBinary, byteBLOB.Length); sqlComm.Prepare(); sqlComm.Parameters["@pict"].Value = byteBLOB; sqlComm.ExecuteNonQuery(); MessageBox.Show("Image Added Successfully in ID: this.txtPatientId.Text.Trim() + " "); } catch (Exception ex) { //MessageBox.Show("Record Not Found","Searching // Result",MessageBoxButtons.OK,MessageBoxIcon.Information); MessageBox.Show(ex.Message); } finally { sqlConn.Close(); } } } } }

" +

patient management system  
Read more
Read more
Similar to
Popular now
Just for you