Professional Documents
Culture Documents
INTRODUCTION
1
1.2 ABOUT THE PROJECT
The first version of CDA was developed in 2001 and Release 2 came out in 2005.
Many CDA-based projects have been successfully completed in many countries. Active
works are being done on improving semantic interoperability based on open EHR and
CEN13606. To ensure interoperability of HIE, the number of HIS that supports CDA
needs to be sufficiently large. However, the structure of CDA is very complex and the
production of correct CDA document is hard to achieve without deep understanding of
the CDA standard and sufficient experience with it.
In addition, the HIS development platforms for hospitals vary so greatly that
generation of CDA documents in each hospital invariably requires a separate CDA
generation system.. The US Government runs the Meaningful Use Program to improve
efficiency in healthcare and patient safety. This program was launched as a part of
incentives to raise the EHR adoption rate for EHR hospitals. The CDA document
pertaining to a patient is generated at the clinic where the patient is diagnosed. The
generated CDA document can be sent to other clinics after patients consent is acquired.
2
1.3 PROBLEM DEFINITION
When well implemented in the context of the clinical workflow, these instruments
can save clinicians time as well as well as assure clinical thoroughness, thus reducing the
chance of medical errors. Stakeholders in basic sciences, health services and medical
informatics research recognize the importance of information captured directly from
episodes of clinical care for research, real-time decision support and patient screening for
clinical trials or clinical syndromes.
Structured entry and reporting systems promise to meet this need by enabling
health care providers to document clinical encounters through selection from pre-defined
categories. Structured entry and reporting systems are designed to enhance the process of
clinical documentation by both presenting useful categorical concepts in a user interface
and capturing input from the end user though the interface as machine-readable data.
Structured entry is achieved as the end user navigates through lists of relevant concepts
and sets status (e.g. present/absent, etc.) or strongly typed values.
The main objectives of these systems are: Capture of raw data in a consistent and
cohesive I manner enabling generation and delivery of reminders and alerts to the point
of care while providing an infrastructure for clinical research. This leads to enhancement
of patient care. Reduce variability in the quality and quantity of concepts recorded as part
of the medical record. This enables research investigators to seamlessly integrate research
questions without impacting the clinical workflow. Although the benefits of structured
entry and reporting systems have been well documented, their widespread
3
implementation and consequent adoption has been limited due to the following reasons.
Inefficiency, complexity and slow pace of navigating through user interfaces to find
relevant content. Inflexibility for documenting unforeseen findings. Lack of integration
with clinical applications Deficiencies in both coverage by and goals of the underlying
domain and document models.
These techniques enable rendering static and dynamic templates that contain
branching logic and manage the impact of definition changes on the creation and
rendering of these documentation templates. The organization of the paper is as follows.
In Section 2, we present a real-world scenario and use case that describes an actual
documentation template implemented at Partners HealthCare. The document and domain
CDA used in the system. We present and discuss the architecture of the system we present
the functionality of the clinical documentation system in the clinical and maintenance
contexts. The organization will used in the CDA document.
4
CHAPTER 2
SYSTEM ANALYSIS
Structured entry and reporting systems promise to meet this need by enabling
health care providers to document clinical encounters through selection from pre-defined
categories. Structured entry and reporting systems are designed to enhance the process of
clinical documentation by both presenting useful categorical concepts in a user interface
and capturing input from the end user though the interface as machine-readable data.
Structured entry is achieved as the end user navigates through lists of relevant concepts
and sets status (e.g. present/absent, etc.) or strongly typed values.
5
In proposed system we presented A CDA documents generation system and
integration system that generates CDA documents. In different developing platforms
integrates multiple CDA documents scattered in different hospitals for each patient. This
system is accessible through Open API developers are easily use their favourite
development platforms such as Java .NET and C/C++. Here Materials and Methods,
detailed explanations made on the format of CDA document.
Cloud computing and the overall architecture of our proposed system and
contrasts it to different HIE system in various countries to point out the strengths of our
system. We chose a widely used cloud service, amozan cloud and provide the CDA
generation and integration system as SaaS. In proposed system we can able to use any
type of platform to accesses the patients information Hospitals are permit to conveniently
generate CDA documents without having to purchase software.
CDA document integration system integrates multiple CDA documents per patient
into a single CDA document and physicians and patients can browse the clinical data in
chronological order. In proposed work is providing security to the CDA document and a
unique identity (id) is generated and given to the patients for avoiding the interchanging
and duplication of medical reports. Every detail in CDA Document is Encrypted and
stored in Database. All Details in CDA Document is secured using various Security
Algorithms.
Inter feasibility between hospitals improve patient safety and quality, and Reduce
time and resource spent on data format conversion.
CDA documents integration system is accessible through Open API.
All the developers are free to use their favorite development platforms.
6
2.3 FEASIBILITY STUDY
The feasibility of the project is analyzed in this phase and business proposal is put
forth with a very general plan for the project and some cost estimates. During system
analysis the feasibility study of the proposed system is to be carried out.
This is to ensure that the proposed system is not a burden to the company. For
feasibility analysis, some understanding of the major requirements for the system is
essential.
Economical feasibility
Technical feasibility
Social feasibility
Managerial Feasibility
Operational Feasibility
This study is carried out to check the economic impact that the system will have
on the organization. The amount of fund that the company can pour into the research and
development of the system is limited.
The expenditures must be justified. Thus the developed system as well within the
budget and this was achieved because most of the technologies used are freely available.
Only the customized products had to be purchased.
This study is carried out to check the technical feasibility, that is, the technical
requirements of the system. Any system developed must not have a high demand on the
available technical resources. Technical Feasibility centres on the existing computer
system hardware, software, etc. This will lead to high demands on the available technical
resources. This will lead to high demands being placed on the client.
7
2.3.3 Social Feasibility
The aspect of study is to check the level of acceptance of the system by the user.
This includes the process of training the user to use the system efficiently. The user must
not feel threatened by the system, instead must accept it as a necessity. The user must not
feel threatened by the system, instead must accept it as a necessity. The level of
acceptance by the users solely depends on the methods that are employed to educate the
user about the system and to make him familiar with it.
The level of acceptance by the users solely depends on the methods that are
employed to educate the user about the system and to make him familiar with it. His level
of confidence must be raised so that he is also able to make some constructive criticism,
which is welcomed, as he is the final user of the system.
The aspect of study is to check the level of acceptance of the system by the user.
This includes the process of training the user to use the system efficiently. The user must
not feel threatened by the system, instead must accept it as a necessity.
The level of acceptance by the user solely depends on the methods that are
employed to educate the user about the system and to make him familiar with it. His level
of confidence must be raised so that he is also able to make some constructive criticism,
which is welcomed, as he is the final user of the system.
8
2.4 USER INTERFACE REQUIREMENTS
Admin Module
An admin of a Hospital is a member that will enter the details of the patient, and
maintain the data in the database and provide the protocol for patients when to come and
give appointment. They will send that reports to doctors. Maintain authentication login,
and acts as mediator between user/patient and Doctor. Patients Medical record data is
critical for the analysis and research purposes. This data includes patient history,
observation, diagnosis and therapeutic conclusions along with the tests details and serves
as a source of information for any analysis and research.
Every patient who visits the hospital has to get registered prior to getting any
consultation, treatment or investigations done. Registration of patients involves accepting
certain general and demographic information about the patient. The patient is allocated a
unique Registration number and a Patient Identification number. The Patient ID will
remain same for his all subsequent visits to the hospital. Whereas he will be allocated a
new registration number on every visit. The consultation charges (if applicable) can also
be collected for the patients during registration and a receipt will be generated. Patients
are who will come to a hospital with different types of diseases, will register and get an
appointment from the admin then consult doctor Follow the doctor precautions and
reports are taken by doctors.
9
Doctor Module
In this module we can view the todays doctor on call schedule department wise.
Here we can create the duty plan of doctor and edit or update the duty plan of particular
doctor. Here we can add/delete the doctor to particular department. The doctor is a person
who will work in hospital and qualified to treat people who are ill. And provide
prescriptions, and store confidential patient data in database. Refers to another doctor
regarding patient problem and transfers patient information in the form of CDA
document.
10
CHAPTER 3
DEVELOPMENT ENVIRONMENT
The hardware requirements may serve as the basis for a contract for the
implementation of the system and should therefore be a complete and consistent
specification of the whole system. They are used by software engineers as the starting
point for the system design. It should what the system do and not how it should be
implemented.
Hard disk : 40 GB
RAM : 512mb
Processor : Pentium IV
Monitor : 17 Color monitor
11
Code Behind : JAVA,JSP ,J2EE
Back End : SQL SERVER 2008
Operating System : Windows 7.
3.3 LANGUAGE REVIEW
12
network, or local computer). This means that a managed component might or might not
be able to perform file-access operations, registry-access operations, or other sensitive
functions, even if it is being used in the same active application.
This provides built-in support for language interoperability. To ensure that you
can develop managed code that can be fully used by developers using any programming
language, a set of language features and rules for using them called the Common
Language Specification (CLS) has been defined. Components that follow these rules and
expose only CLS features are considered CLS-compliant. The runtime enforces code
access security. For example, users can trust that an executable embedded in a Web page
can play an animation on screen or sing a song, but cannot access their personal data, file
system, or network. The security features of the runtime thus enable legitimate Internet-
deployed software to be exceptionally featuring rich.
The runtime also enforces code robustness by implementing a strict type- and
code-verification infrastructure called the common type system (CTS). The CTS ensures
that all managed code is self-describing. The various Microsoft and third-party language
compilers generate managed code that conforms to the CTS. This means that managed
code can consume other managed types and instances, while strictly enforcing type
fidelity and type safety.
13
compilers that target the .NET Framework make the features of the .NET Framework
available to existing code written in that language, greatly easing the migration process
for existing applications.
3.3.3. .NET Framework Class Library
The .NET Framework class library is a collection of reusable types that tightly
integrate with the common language runtime. The class library is object oriented,
providing types from which your own managed code can derive functionality. This not
only makes the .NET Framework types easy to use, but also reduces the time associated
with learning new features of the .NET Framework. In addition, third-party components
can integrate seamlessly with classes in the .NET Framework.
As you would expect from an object-oriented class library, the .NET Framework
types enable you to accomplish a range of common programming tasks, including tasks
such as string management, data collection, database connectivity, and file access. In
addition to these common tasks, the class library includes types that support a variety of
specialized development scenarios. For example, you can use the .NET Framework to
develop the following types of applications and services:
Console applications.
Scripted or hosted applications.
Windows GUI applications (Windows Forms).
ASP.NET applications.
XML Web services
3.4 JAVA
3.4.1 JSP Language Specification
A JSP page is a textual document that describes how to create a response object
from a request object for a given protocol. The processing of the JSP page may involve
creating and/or using other objects. A JSP page defines a JSP page implementation class
that implements the semantics of the JSP page. This class implements the
javax.servlet.Servlet interface (see Chapter JSP.11, JSP Container for details). At
14
request time a request intended for the JSP page is delivered to the JSP page
implementation object for processing. HTTP is the default protocol for requests and
responses. Additional request/response protocols may be supported by JSP containers.
The default request and response objects are of type HttpServletRequest and
HttpServletResponse respectively.
15
document; this means that a JSP document is a well-formed, structured document and
that this will be validated by the JSP container. Additionally, this structure will be
available to the JSP validation machinery, the TagLibraryValidators.
A JSP document is a namespace-aware XML document, with namespaces
reflecting the structure of both content and custom actions and with some additional care,
a JSP page can reflect quite accurately the structure of the resulting content. A JSP
document can also use machinery like entity definitions. The JSP 1.2 specification made
a stronger distinction between JSP documents and non-XML JSP pages. For instance
standard actions like <jsp:expression> were only available in JSP documents. The
difference proved to be confusing and distracting and the distinction has been relaxed in
JSP 2.0 to facilitate the transition from the JSP syntax to XML syntax.
During the execution phase the JSP container delivers events to the JSP page
implementation object. The container is responsible for instantiating request and response
objects and invoking the appropriate JSP page implementation object. Upon completion
of processing, the response object is received by the container for communication to the
16
client. The details of the contract between the JSP page implementation class and the JSP
container are described in Chapter JSP.11, JSP Container.
3.5.2 History
SQL was initially developed at IBM by Donald D. Chamberlin and Raymond F.
Boyce in the early 1970s. This version, initially called SEQUEL (Structured English
17
Query Language), was designed to manipulate and retrieve data stored in IBM's original
quasi-relational database management system, System R, which a group at IBM San Jose
Research Laboratory had developed during the 1970s. As data processing has become
more sophisticated, so have methods for collecting The acronym named as the SEQUEL
was later changed to SQL because "SEQUEL" was a trademark of the UK-based Hawker
Siddeley aircraft company.
In the late 1970s, Relational Software, Inc. (now Oracle Corporation) saw the
potential of the concepts described by Cod, Chamberlin, and Boyce and developed their
own SQL-based RDBMS with aspirations of selling it to the U.S. Navy, Central
Intelligence Agency, and other U.S. government agencies. Fully qualified names are
object references that are prefixed with the name of the namespace.
The acronym SEQUEL was later changed to SQL because "SEQUEL" was a
trademark of the UK-based Hawker Siddeley aircraft company. In June 1979, Relational
Software, Inc. introduced the first commercially available implementation of SQL,
Oracle V2 (Version2) for VAX computers. After testing SQL at customer test sites to
determine the usefulness and practicality of the system, IBM began developing
commercial products based on their System R prototype including System/38, SQL/DS,
and DB2, which were commercially available in 1979, 1981, and 1983, respectively.
18
Unlike most MS-DOS programs at the time, Microsoft Word was designed to be
used with a mouse. Advertisements depicted the Microsoft Mouse, and described Word as
a WYSIWYG, windowed word processor with the ability to Undo and display bold,
italic, and underlined text, although it could not render fonts.
CHAPTER 4
SYSTEM DESIGN
The data model is also called as bubble chart. It is a simple graphical formalism
that can be used to represent a system in terms of the input data to the system, various
processing carried out on these data, and the output data is generated by the system.
Table design
patient_id Varchar(50)
doctor_id Varchar(50)
Disease Varchar(50)
Date Varchar(50)
Test Varchar(50)
Blood Varchar(50)
Urine Varchar(50)
Bp Varchar(50)
x_ray Varchar(50)
Scan Varchar(50)
ct_scan Varchar(50)
20
Ecg Varchar(50)
21
4.2.1 Data Flow diagram
A DFD shows what kinds of data will be input to and output from the system, the
data will come from and go to, and where the data will be stored.
Level 0 DFD
Level 1 DFD
22
Level 2 DFD
Level 3 DFD
23
Fig 4.1 Data Flow Diagram
24
The use case diagram is used to show the users and the operations involved in the
application. The main purpose of a use case diagram is to show what system functions are
performed for which actor. Roles of the actors in the system can be depicted. Use case
diagrams overview the usage requirement for the system. They are useful for
presentations to management and/or project stakeholders.
25
Fig 4.2 Use Case Diagram
26
4.2.3 Sequence Diagram
27
CHAPTER 5
SYSTEM IMPLEMENTATION
5.1 CODING
28
//Connection conn =
DriverManager.getConnection("jdbc:mysql://localhost:3306/javademo?" +
"user=root&password=");
Connection conn = DriverManager.getConnection("jdbc:sqlserver://5b0530ba-83fb-
4d44-9be6-
a5a700567563.sqlserver.sequelizer.com\\.:1433;databaseName=db5b0530ba83fb4d449be
6a5a700567563","jihyzfgjercuvkbq","GvUwoXSJCPLFeLbMLdYZZifRbVpCLNbAbC
ZTyyBFHPDpGQrGNykWHmWypduAHp6W");
String uname1=(String)session.getAttribute("h");
String n=request.getParameter("pat");
String st="Request";
PreparedStatement check2 = conn.prepareStatement("Select MAX(id) from patient1");
ResultSet rs2 = check2.executeQuery();
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
<script type="text/javascript">
function f()
{
window.location="loginform.jsp";
}
function f1()
{
var a=document.getElementById('desease1').value;
29
}
else if(a==='heart attack' ||a==='heart pain')
{
document.getElementById('doctor1').value='Cardialogy';
}
}
</script>
<style>
.button {
background-color:#3090C7;
border: none;
color: white;
padding: 12px 28px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 12px;
margin: 4px 2px;
cursor: pointer;
}
</style>
</head>
<body bgcolor="blue">
<form action="patient1.jsp" method="post"><center>
<h5>REGISTRATION</h5>
<table border="1" background="blue">
<tr border="0" >
<% while(rs2.next())
{
30
int id1=0;
id1=rs2.getInt(1);
id1++;
%>
<td> <b>ID</b></td><td><input type="text" name="id1" id="id" value="<%=id1%>"
></td></tr>
<%}%>
<tr><td><b>NAME</b></td><td><input type="text" name="name1"
id="username1"/></td></tr>
</br>
<tr><td><b>HEIGHT</b></td><td> <input type="text" name="height"
id="password1"/></td></tr>
31
<!--<div class="Login">
<div class="Login-head">
<h3>LOGIN</h3>
</div>
<form>
<div class="ticker">
<h4>Username</h4>
<input type="text" value="John Smith" onfocus="this.value = '';" onblur="if (this.value
== '') {this.value = 'John Smith';}" ><span> </span>
<div class="clear"> </div>
</div>
<div>
<h4>Password</h4>
<input type="password" value="Password" onfocus="this.value = '';" onblur="if
(this.value == '') {this.value = 'Password';}" >
<div class="clear"> </div>
</div>
<div class="checkbox-grid">
<div class="inline-group green">
<label class="radio"><input type="radio" name="radio-inline"><i> </i>Remember
me</label>
<div class="clear"> </div>
</div>
</div>
<div class="submit-button">
<input type="submit" onclick="" value="LOGIN " >
</div>
<div class="clear"> </div>
</div>
</form>
32
</div>
</div>-->
<!--//End-login-form-->
</body></html>
REQUEST:
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<%@page import="java.sql.ResultSet"%>
<%@page import="java.sql.PreparedStatement"%>
<%@page import="java.sql.Statement"%>
<%@page import="java.sql.DriverManager"%>
<%@page import="java.sql.Connection"%>
<%@include file="adminpage.jsp"%>
<%
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver"); // MySQL database
connection
//Connection conn =
DriverManager.getConnection("jdbc:mysql://localhost:3306/javademo?" +
"user=root&password=");
Connection conn = DriverManager.getConnection("jdbc:sqlserver://5b0530ba-83fb-
4d44-9be6-
a5a700567563.sqlserver.sequelizer.com\\.:1433;databaseName=db5b0530ba83fb4d449be
6a5a700567563","jihyzfgjercuvkbq","GvUwoXSJCPLFeLbMLdYZZifRbVpCLNbAbC
ZTyyBFHPDpGQrGNykWHmWypduAHp6W");
PreparedStatement check2 = conn.prepareStatement("Select * from prescription where
status='Request'");
ResultSet rs2 = check2.executeQuery();
while(rs2.next())
33
{
String a=rs2.getString("id");
String b=rs2.getString("desease");
String c=rs2.getString("date");
String d=rs2.getString("blood");
String e=rs2.getString("urine");
String f=rs2.getString("bp");
String g=rs2.getString("xr");
String h=rs2.getString("scan");
String i=rs2.getString("ecg");
String j=rs2.getString("pres");
String k=rs2.getString("status");
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<form action="accept.jsp" method="post">
<center>
<table border="1" cellpadding="5" cellspacing="5">
<tr>
<th>ID</th>
<th>SYMPTOMS</th>
<th>DATE</th>
<th>BLOOD</th>
<th>URINE</th>
<th>BP</th>
<th>XRAY</th>
34
<th>SCAN</th>
<th>ECG</th>
<th>PRESCRIPTION</th>
<th>STATUS</th>
</tr>
<tr>
<td><input type="checkbox" name="id1" value="<%=a%>"><%=a%></td>
<td><%=b%></td>
<td><%=c%></td>
<td><%=d%></td>
<td><%=e%></td>
<td><%=f%></td>
<td><%=g%></td>
<td><%=h%></td>
<td><%=i%></td>
<td> <%=j%></td>
<td> <%=k%></td>
</table>
<%}%>
<input type="submit" value="Submit">
</form>
</center>
</body>
</html>
36
TextBox12.Text + "','" + TextBox6.Text + "','" + TextBox9.Text + "','" + TextBox10.Text
+ "','" + TextBox11.Text + "','" + TextBox7.Text + "','" + TextBox8.Text + "','" +
DateTime.Now.ToString() + "','"+TextBox14.Text+"')";
cd.ExecuteNonQuery();
con.Close();
Response.Write("<script>alert('Registered successfully')</script>");
con.Close();
}
//protected void Button1_Click(object sender, EventArgs e)
//{
// con.Open();
// SqlCommand cd = con.CreateCommand();
// cd.CommandType = CommandType.Text;
// cd.CommandText = "insert into dean_doctor values('" + TextBox1.Text +
"','"+TextBox2.Text+"','" + DropDownList1.SelectedItem.ToString() + "','" +
TextBox13.Text + "','" + TextBox3.Text + "','" + TextBox4.Text + "','" + TextBox5.Text +
"','" + TextBox12.Text + "','" + TextBox6.Text + "','" + TextBox9.Text + "','" +
TextBox10.Text + "','" + TextBox11.Text + "','"+Label14.Text+"','" + TextBox7.Text +
"','" + TextBox8.Text + "','" + DateTime.Now.ToString() + "')";
// cd.ExecuteNonQuery();
// con.Close();
// Response.Write("<script>alert('Registered successfully')</script>");
// con.Close();
//}
//protected void Button2_Click(object sender, EventArgs e)
//{
// Random ran = new Random();
// int doctorid = ran.Next(232, 14567);
// Label14.Text = "d" + doctorid.ToString();
//}}}
37
Doctorview.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm8 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
Label1.Text = Convert.ToString(Session["doctorid"]);
con.Open();
SqlCommand cmd = new SqlCommand("select
first_name,age,diseases,patient_id,date_time from opform where assigned_doctorid = '" +
Label1.Text + "'", con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
con.Close();
}
38
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd = con.CreateCommand();
cd.CommandType = CommandType.Text;
string interests = string.Empty;
foreach (ListItem item in this.CheckBoxList1.Items)
if (item.Selected)
interests += item + ",";
cd.CommandText = "insert into patient_diseases values('" + TextBox1.Text + "','" +
TextBox2.Text + "','" + TextBox15.Text + "','" + interests + "','" + TextBox3.Text + "','" +
Label1.Text + "','" + DateTime.Now.ToString()+ "','nill','nill','')";
cd.ExecuteNonQuery();
Session["patientid"] = TextBox1.Text;
con.Close();
Response.Write("<script>alert('Registered successfully')</script>");
con.Close();
}}}
Dvpatient_Report.aspx
using System;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data;
using System.Data.SqlClient;
39
using System.Text;
using System.IO;
using iTextSharp.text;
using iTextSharp.text.pdf;
using iTextSharp.text.html;
using iTextSharp.text.html.simpleparser;
namespace cda_pro
{
public partial class WebForm15 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
TextBox2.Text = DateTime.Now.ToString();
}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
DataTable dt = new DataTable();
SqlDataReader myReader = null;
SqlCommand cd = con.CreateCommand();
cd.CommandType = CommandType.Text;
cd.CommandText = "select * from opform where patient_id='" + TextBox1.Text + "'";
myReader = cd.ExecuteReader();
while (myReader.Read())
{
TextBox3.Text = (myReader["first_name"].ToString());
TextBox4.Text = (myReader["age"].ToString());
TextBox5.Text = (myReader["diseases"].ToString());
TextBox6.Text = (myReader["assigned_doctor"].ToString());
40
TextBox7.Text = (myReader["date_time"].ToString());
}
con.Close();
con.Open();
DataTable dt1 = new DataTable();
SqlDataReader myReader1 = null;
SqlCommand cd1 = con.CreateCommand();
cd1.CommandType = CommandType.Text;
cd1.CommandText = "select * from patient_diseases where patient_id='" +
TextBox1.Text + "'";
myReader1 = cd1.ExecuteReader();
while (myReader1.Read())
{
TextBox8.Text = (myReader1["symptoms"].ToString());
TextBox9.Text = (myReader1["test"].ToString());
TextBox10.Text = (myReader1["prescription"].ToString());
TextBox11.Text = (myReader1["final_prescription"].ToString());
}
con.Close();
}
protected void Button3_Click(object sender, EventArgs e)
{
//Get the data from database into datatable
string strQuery = "select
first_name,surname,gender,age,address,phone_no,diseases,patient_id,assigned_doctor
from opform where patient_id='" + TextBox1.Text + "'" ;
string strQuery1 = "select date,doctor_id,[diseases],[symptoms],[test],[prescription],
[final_prescription],[final_prescription_date] from [patient_diseases] where patient_id ='"
+ TextBox1.Text + "'";
41
string strQuery2 = "select [date],[patient_id],[disease],[test],[blood],[urine] ,[diabetes] ,
[bp],[x_ray],[scan] ,[ct_scan],[ecg],[lab_report_date] from labtest_details where
patient_id ='" + TextBox1.Text + "'";
string strQuery3 = "select [patient_id],[diseases],[final_prescription],
[final_prescription_date] from [patient_diseases] where patient_id ='" + TextBox1.Text +
"'";
SqlCommand cmd = new SqlCommand(strQuery);
SqlCommand cmd1 = new SqlCommand(strQuery1);
SqlCommand cmd2= new SqlCommand(strQuery2);
SqlCommand cmd3 = new SqlCommand(strQuery3);
DataTable dt = GetData(cmd);
DataTable dt1 = GetData(cmd1);
DataTable dt2 = GetData(cmd2);
DataTable dt3 = GetData(cmd3);
//Create a dummy GridView
GridView GridView1 = new GridView();
GridView1.AllowPaging = false;
GridView1.DataSource = dt;
GridView1.DataBind();
GridView GridView2 = new GridView();
GridView2.AllowPaging = false;
GridView2.DataSource = dt1;
GridView2.DataBind();
GridView GridView3 = new GridView();
GridView3.AllowPaging = false;
GridView3.DataSource = dt2;
GridView3.DataBind();
GridView GridView4 = new GridView();
GridView4.AllowPaging = false;
GridView4.DataSource = dt3;
42
GridView4.DataBind();
Response.Clear();
Response.Buffer = true;
Response.AddHeader("content-disposition", "attachment;filename=patient_report.doc");
Response.Charset = "";
Response.ContentType = "application/vnd.ms-word ";
StringWriter sw = new StringWriter();
StringWriter sw1 = new StringWriter();
StringWriter sw2= new StringWriter();
StringWriter sw3= new StringWriter();
HtmlTextWriter hw = new HtmlTextWriter(sw);
HtmlTextWriter hw1 = new HtmlTextWriter(sw1);
HtmlTextWriter hw2= new HtmlTextWriter(sw2);
HtmlTextWriter hw3= new HtmlTextWriter(sw3);
GridView1.RenderControl(hw);
GridView2.RenderControl(hw1);
GridView3.RenderControl(hw2);
GridView4.RenderControl(hw3);
Response.Output.Write(sw.ToString());
Response.Output.Write(sw1.ToString());
Response.Output.Write(sw2.ToString());
Response.Output.Write(sw3.ToString());
Response.Flush();
Response.End();
Response.Write("*********************************************************
*******************");
}
private DataTable GetData(SqlCommand cmd)
{
DataTable dt = new DataTable();
43
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
//String strConnString =
System.Configuration.ConfigurationManager.ConnectionStrings["conn"].ConnectionStri
ng;
//SqlConnection con = new SqlConnection(con);
SqlDataAdapter sda = new SqlDataAdapter();
cmd.CommandType = CommandType.Text;
cmd.Connection = con;
try
{
con.Open();
sda.SelectCommand = cmd;
sda.Fill(dt);
return dt;
}
catch (Exception ex)
{
throw ex;
}
finally
{
con.Close();
sda.Dispose();
con.Dispose();
}}}}
Dvpatientlab_details.aspx
using System;
using System.Collections.Generic;
using System.Linq;
44
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm14 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
Label1.Text = Convert.ToString(Session["doctorid"]);
Label4.Text = Convert.ToString(Session["patientid"]);
con.Open();
SqlCommand cmd = new SqlCommand("select
patient_id,disease,blood,urine,diabetes,bp,x_ray,scan,ct_scan,ecg,lab_report_date from
labtest_details where doctor_id = '" + Label1.Text + "'", con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
con.Close();
}
protected void Button1_Click1(object sender, EventArgs e)
{
con.Open();
SqlCommand cd1 = con.CreateCommand();
45
cd1.CommandType = CommandType.Text;
cd1.CommandText = "update patient_diseases set final_prescription='" + TextBox1.Text
+ "', final_prescription_date='" + DateTime.Now.ToString() + "' where patient_id='" +
Label4.Text + "' and doctor_id='"+Label1.Text+"'";
cd1.ExecuteNonQuery();
con.Close();
}}}
Labview.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm12 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
con.Open();
SqlCommand cmd = new SqlCommand("select patient_id,diseases,test,doctor_id from
patient_diseases where test != 'null'", con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
46
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
con.Close();
}
47
SqlCommand cd = con.CreateCommand();
cd.CommandType = CommandType.Text;
cd.CommandText = "insert into labtest_details values('" + TextBox1.Text + "','"
+TextBox3.Text + "','" + TextBox2.Text + "','" + TextBox16.Text + "','" + TextBox15.Text
+ "','" + TextBox17.Text + "','" + TextBox18.Text + "','" + TextBox19.Text + "','" +
TextBox20.Text + "','" + TextBox21.Text + "','" + TextBox22.Text + "','" +
TextBox23.Text + "','" + TextBox24.Text + "','" + DateTime.Now.ToString() + "')";
cd.ExecuteNonQuery();
con.Close();
Response.Write("<script>alert('Lab test done successfully')</script>");
con.Close();
}}}
Opform.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.IO;
using System.Net;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
using System.Net.Mail;
using System.Text;
namespace cda_pro
{
public partial class WebForm7 : System.Web.UI.Page
48
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
}
//protected void Button2_Click(object sender, EventArgs e)
//{
// Random ran = new Random();
// int patientid = ran.Next(232, 14567);
// Label10.Text = "P" + patientid.ToString();
//}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd = con.CreateCommand();
cd.CommandType = CommandType.Text;
cd.CommandText = "insert into opform values('" + TextBox1.Text + "','" +
TextBox2.Text + "','" + DropDownList1.SelectedItem.ToString() + "','" + TextBox3.Text
+ "','" + TextBox4.Text + "','" + TextBox5.Text + "','" + TextBox6.Text + "','" +
Label10.Text + "','" + TextBox7.Text + "','" + TextBox8.Text + "','" +
DateTime.Now.ToString() + "','"+TextBox9.Text+"')";
cd.ExecuteNonQuery();
con.Close();
Response.Write("<script>alert('Registered successfully')</script>");
con.Close();
}
protected void Button2_Click(object sender, EventArgs e)
{
Random ran = new Random();
int patientid = ran.Next(232, 14567);
49
Label10.Text = "P" + patientid.ToString();
}
protected void Button3_Click(object sender, EventArgs e)
{
DataTable dt = new DataTable();
con.Open();
SqlDataReader myReader = null;
SqlCommand myCommand = new SqlCommand("select
assigned_roomno,assigned_doctorid,doctor_name from dean_doctor where general='" +
TextBox6.Text + "'", con);
myReader = myCommand.ExecuteReader();
while (myReader.Read())
{
TextBox7.Text = (myReader["assigned_roomno"].ToString());
TextBox8.Text = (myReader["assigned_doctorid"].ToString());
TextBox9.Text = (myReader["doctor_name"].ToString());
}
con.Close();
}}}
Patient_View.aspx
using System;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data;
50
using System.Data.SqlClient;
using System.Text;
using System.IO;
using iTextSharp.text;
using iTextSharp.text.pdf;
using iTextSharp.text.html;
using iTextSharp.text.html.simpleparser;
namespace cda_pro
{
public partial class WebForm9 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
// SqlConnection con = new
SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button2_Click(object sender, EventArgs e)
{
con.Open();
DataTable dt = new DataTable();
SqlDataReader myReader = null;
SqlCommand cd = con.CreateCommand();
cd.CommandType = CommandType.Text;
cd.CommandText = "select * from opform where patient_id='" + TextBox1.Text + "'";
myReader = cd.ExecuteReader();
while (myReader.Read())
{
TextBox3.Text = (myReader["first_name"].ToString());
TextBox4.Text = (myReader["age"].ToString());
51
TextBox5.Text = (myReader["diseases"].ToString());
TextBox6.Text = (myReader["assigned_doctor"].ToString());
TextBox7.Text = (myReader["date_time"].ToString());
}
con.Close();
con.Open();
DataTable dt1 = new DataTable();
SqlDataReader myReader1 = null;
SqlCommand cd1 = con.CreateCommand();
cd1.CommandType = CommandType.Text;
cd1.CommandText = "select * from patient_diseases where patient_id='" +
TextBox1.Text + "'";
myReader1 = cd1.ExecuteReader();
while (myReader1.Read())
{
TextBox8.Text = (myReader1["symptoms"].ToString());
TextBox9.Text = (myReader1["test"].ToString());
TextBox10.Text = (myReader1["prescription"].ToString());
TextBox11.Text = (myReader1["final_prescription"].ToString());
}
con.Close();
}}}
Requestpatient.aspx
using System;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
52
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data;
using System.Data.SqlClient;
using System.Text;
using System.IO;
namespace cda_pro
{
public partial class WebForm16 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd1 = con.CreateCommand();
cd1.CommandType = CommandType.Text;
cd1.CommandText = "update prescription set status='Request' where [id]='" +
TextBox1.Text + "' ";
cd1.ExecuteNonQuery();
con.Close();
}}}
signin.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
53
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm5 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd = new SqlCommand("select * from dean_doctor where
assigned_doctorid='" + TextBox1.Text + "' and dob='" + TextBox2.Text + "'", con);
SqlDataReader dr = cd.ExecuteReader();
if (dr.Read())
{
//Response.Write("<script>alert('username or password mismatch')</script>");
Session["doctorid"] = TextBox1.Text;
Response.Redirect("doctorview.aspx");
}
else
{ Response.Write("<script>alert('username or password mismatch')</script>");
//Response.Redirect("doctor.aspx");
}
con.Close();}}}
54
Signinpatient.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm6 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd = new SqlCommand("select * from opform where patient_id='" +
TextBox1.Text + "' and phone_no='" + TextBox2.Text + "'", con);
SqlDataReader dr = cd.ExecuteReader();
if (dr.Read())
{
//Response.Write("<script>alert('username or password mismatch')</script>");
Response.Redirect("patient_view.aspx");
}
55
else
{
Response.Write("<script>alert('ID OR PASSWORD MISMATCH')</script>");
//Response.Redirect("doctor.aspx");
}
con.Close();}}}
Viewjavapatient.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm18 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
con.Open();
SqlCommand cmd = new SqlCommand("select
id,desease,date,blood,urine,bp,xr,scan,ecg,pres from prescription where Status='Accept'",
con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
56
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
con.Close();
}}}
Viewrequest.aspx
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;
using System.Configuration;
namespace cda_pro
{
public partial class WebForm17 : System.Web.UI.Page
{
SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["conn"]);
protected void Page_Load(object sender, EventArgs e)
{
con.Open();
SqlCommand cmd = new SqlCommand("select
patient_id,diseases,symptoms,test,prescription,doctor_id,final_prescription,Status from
patient_diseases where Status= 'Request'", con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
DataSet ds = new DataSet();
da.Fill(ds);
57
GridView1.DataSource = ds;
GridView1.DataBind();
con.Close();
}
protected void Button1_Click(object sender, EventArgs e)
{
con.Open();
SqlCommand cd1 = con.CreateCommand();
cd1.CommandType = CommandType.Text;
cd1.CommandText = "update patient_diseases set Status='Accept' where patient_id='" +
TextBox1.Text + "'";
cd1.ExecuteNonQuery();
con.Close();
}}}
Web.config
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<appSettings>
<add key="ValidationSettings:UnobtrusiveValidationMode" value="None" />
<!--<add key="con" value="Data Source=INETZ-06;Initial Catalog=dedulication;User
ID=sa;password=inetz"/>
<add key="conn" value="Data Source=INETZ-09;Initial Catalog=dedulication;User
ID=sa;password=inetz"/>-->
<add key="conn" value="Data Source=5b0530ba-83fb-4d44-9be6-
a5a700567563.sqlserver.sequelizer.com;Initial
58
Catalog=db5b0530ba83fb4d449be6a5a700567563;User
ID=jihyzfgjercuvkbq;password=GvUwoXSJCPLFeLbMLdYZZifRbVpCLNbAbCZTyy
BFHPDpGQrGNykWHmWypduAHp6W"/>
<!--<add key="con" value="Data Source=1051be86-75f5-4bc1-ac91-
a4ab00ddc6cb.sqlserver.sequelizer.com;Initial
Catalog=db1051be8675f54bc1ac91a4ab00ddc6cb;User
ID=krirelbavjasgqbd;password=y6gc8WrsvmtmvrZHycYJRtigzEqunUYG4NQTEZ2Ky
bu7fZLGDztmVzzeV8JAF5eH"/>-->
</appSettings>
<connectionStrings>
<!--<add name="conString" connectionString="Data Source=INETZ-5-PC;Initial
Catalog=CDA;Integrated Security=True"/>-->
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.0" />
</system.web>
</configuration>
59
CHAPTER 6
TESTING
Unit testing is a test of a simple piece of code. As already mentioned, that the
system has been developed by module wise and the first phase of testing must be module
wise testing. In this system each module has been individually executed to confirm that
no syntax error or run time error occurs. It is made sure that the validation for each input
data works proper.
Integration testing is the next level. The module of the system has first taken and
according to the linkage priority each modules have been integrated into the system. This
Integration test is performed in order to verify that the system works according to the
requirements even after integration of all modules. Integration testing in this project, is
the phase in software testing in which individual software modules are combined and
tested as a group. Integration testing takes as its input modules that have been unit tested,
group them in larger aggregates, applies tests defined in an integration test plan to those
aggregates, and delivers as its output the integrated system ready for system testing.
60
6.1.1.3 Functional test
System testing ensures that the entire integrated software system meets
requirements. It tests a configuration to ensure known and predictable results. An
example of system testing is the configuration oriented system integration test. System
testing is based on process descriptions and flows, emphasizing pre-driven process links
and integration points.
White Box Testing is a testing in which in which the software tester has
knowledge of the inner workings, structure and language of the software, or at least its
purpose. It is purpose. It is used to test areas that cannot be reached from a black box
level.
Black Box Testing is testing the software without any knowledge of the inner
workings, structure or language of the module being tested. Black box tests, as most other
kinds of tests, must be written from a definitive source document, such as specification or
requirements document, such as specification or requirements document.
User Acceptance Testing is a critical phase of any project and requires significant
participation by the end user. It also ensures that the system meets the functional
requirements.
61
6.1.1.8 Validation Testing
Test plan specifies objectives if testing for completion criteria, system integration
plan, methods to be used on modules and particular test cases to be used.
The four types of test that a software product must satisfy are:
Function Test specifies operating conditions, input values and expected result.
Performance Test verify response time, execution time and throughout
primary and secondary memory utilization links.
Stress Test is to determine the limitations of the system.
Structural Test is concerned with examining the internal processing logic of a
software system.
It is the process of exercising software with the intent of ensuring that the
software system meets its requirements and user expectations and does not fail in
unacceptable manner.
62
CHAPTER 7
7.1 PERFORMANCE
Inter feasibility between hospitals improve patient safety and quality, and Reduce
time and resource spent on data format conversion. CDA documents integration system is
accessible through Open API. All the developers are free to use their favorite
development platforms.
7.2 LIMITATION
63
Decreased overall efficiency for generating complex documents. We present a
semantics-based infrastructure that seeks to address some of the abovementioned
issues.
7.3 CONCLUSION
The clinical data for the patient in question is provided to his/her doctor in
chronological order per section so that it helps physicians to practice evidence-based
medicine. In the field of document-based health information exchange, the IHE XDS
profile is predominant and our cloud computing system can be readily linked with the
IHE XDS profile. The approach employed in this paper is applicable in adopting other
standards, too, such as the EHR Extract based on openEHR. If a hospital sends the
content archetype, admin archetype, and demographic archetype to the cloud server, then
the server extracts necessary information from each archetype. Next, it generates an
Extract containment structure that fits with a designated template and returns the structure
to the hospital.
64
7.4 FUTURE ENHANCEMENT
Future work will attempt to enhance security while ensuring reasonable quality of
service even with multiple users logged on the system at the same time. We will make a
concrete estimation of the reduction in cost that is cloud based. Cloud computing is
effective and efficient in cost reduction and the medical field seems to be no exception.
65
CHAPTER 8
APPENDICES
JAVA
66
Fig 8.1 Home Page
67
Fig 8.2 Admin Login Page
68
Fig 8.3 Patient Registration Page
69
Fig 8.4 Accept other hospital Request Page
70
Fig 8.5 Doctor Login Page
71
Fig 8.6 Doctor view the patient details Page
72
Fig 8.7 Send to lab test Page
73
Fig 8.8 Lab Page
74
Fig 8.9 Patient details Page
75
DOT NET
76
Fig 8.10 Login Page
77
Fig 8.11 View another hospital patient details Page
78
Fig 8.12 Send Request Page
79
Fig 8.13 Token message Page
80
CHAPTER 9
REFERENCES
Programming in C# - Deitel&Deitel
Asp.net The Complete Reference Mathew MacDonald
Asp.net 3.5 Ajax Unleashed Robert Foster
Generating Standardized Clinical Documents for Medical Information
Exchanges M.l.Pan
Application of portable CDA for secure clinical document exchange
K.Huang
Clinical Document Architecture integration system I.Kim
81
www.w3schools.com
http://www.tutorialspoint.com
www.codeproject.com
82