computer project

41
ACKNOWLEDGEMENT First of all We would like to express our heartful thanks to ” The Almighty God” for this opportunity, which he rendered to us and gives the physical strength and pleasant mind to complete this project work. We thank our honorable Principal VASANTHI BHAT, for her inspiration. And we thank for our project guide for the correct guidance and advice. We also thank our department staff MS ARCHANA KRISHNAN (HEAD OF THE DEPARTMENT Ms.RANI BOPAIAH (CO-ORDINATOR) who all encourage and satisfy our needs to finish this project work. We extent our thanks and gratitude to our parents, Friends and those who helped us directly and indirectly for the successful completion of this project work. CONTENTS S.No Contents 1. Introduction

Upload: varun-yadav

Post on 16-Aug-2015

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Computer project

ACKNOWLEDGEMENTFirst of all We would like to express our heartful thanks to ” TheAlmighty God” for this opportunity, which he rendered to us and gives thephysical strength and pleasant mind to complete this project work.We thank our honorable Principal VASANTHI BHAT, for her inspiration. And we thank for ourproject guide for thecorrect guidance and advice.We also thank our department staff MS ARCHANA KRISHNAN (HEAD OF THE DEPARTMENT Ms.RANI BOPAIAH (CO-ORDINATOR)who all encourage and satisfy our needs to finish this project work.We extent our thanks and gratitude to our parents, Friends and those whohelped us directly and indirectly for the successful completion of thisproject work.CONTENTSS.No Contents1. Introduction Synopsis Company Profile2. Project Objective Input Design Output Design

Page 2: Computer project

9. Sample Codings10. Screenshots11. BibiliographyINTRODUCTIONSYNOPSISThis project will automate the daily operations of LIFE LINE hospital.The project keeps track of the staff and patient (in-patient, out-patient) details. Italso takes care of the ward, medical, invoice and the doctor’s appointmentdetails. The system generates the daily ward availability, the status of theoperation theatres and ICU.HOSPITAL MANAGEMENT is an integrated Hospital InformationSystem, which addresses all the major functional areas of multi-specialtyhospitals. The HOSPITAL MANAGEMENT enables better patient care, patientsafety, patient confidentiality, efficiency, reduced costs and better managementinformation system. It provides easy access to critical information thus enablingthe management to take better decisions on time.This project deals with processing of each and every department in thehospital. This project sincerely aims to reduce the manual processing of eachdepartment.

Page 3: Computer project

The Scope of the project takes care of the details of each and everydepartment. These details gives the doctor, staffs, specialists and patient detailsincluding their salary, attendance , doctor’s appointments and the billingsystem. The details of Doctor and staff help the hospital to maintain the recordof every person. Their attendance details help them to know about their attentivepresence while salary is calculated. The billing system provides an efficient wayfor calculating bill details of the patients.COMPANY PROFILEGVHospitals is a multi-specialty, tertiary care hospitalextending quality health care service to people in and around BANGALOE for thepast 12 years. The hospital was founded by G.V.VARUN The hospital is located at MALLESHWARAM Its head officeis located at MYSORE PROJECT OBJECTIVEPROJECT OBJECTIVE To computerize all details regarding patient details & hospital details. To automate the process of ward entries. To maintain records effectively.

Page 4: Computer project

To manage current status of staff and doctor availablity. The project has information regarding the inpatient details, outpatientdetails, Billing details and Ambulance details.This project includes modules such as1) Admission Inpatient Outpatient2) Staff Details Payroll Personnel Details Attendance On Duty Shift3) Billing Inpatient Outpatient4) Consultation5) Ward Details6) Ambulance Service Driver AmbulanceMODULES REQUIREDAdmission :This module records basic patient related information, which is collectedwhen the patient visits the hospital for the first time. Each patient is allocated

Page 5: Computer project

a unique patient identification numbers also known as Hospital No.Patient Details:It keeps track of all details about both in-patient and out-patient.Patient id, patient name, address, admitted date, doctor name, room no areentered in a form and stored for future reference. Also particular patient detailscan be viewed in the table using a separate form with a attribute patient id.Outpatient:This module manages activities related to patient who visits the HospitalResident Doctor or Consultant Doctor for Medical Consultations, diagnosis andtreatment.Inpatient:Admission request will be made here. Request for admission is madebefore patient admitting the hospital.Staff Details:It keeps track of all details about doctors and staffs of the hospital. staffs,Doctors, Nurses name, staff id, address, qualification, cell no, e-mail are enteredand stored in a separate form. Individual staff details can be viewed in the tableusing a separate form with a attribute Staff id.Salary Details:

Page 6: Computer project

This module contains the details salary for the doctors and nurse. Thissalary calculated basic salary, PF, HRA, and year increment for the staffs fromdate of joining automatically calculated.Consultation Details :This module contains the details for the inpatient which includes diseasename, type of treatment and medicine given to them.Billing Details:This module bills the both inpatient and outpatient who comes to hospital.Ward Details:This module enters and stores the details about each ward of the hospitalfor future reference. Individual ward detail can be viewed in the table usingward id .The attributes used in storing a ward detail is ward id, ward name,floor no, no of rooms.Ambulance Services:Another service for Ambulance availability, out time, in time, search forthe ambulance went to place for petrol and fuel expenses.SYSTEMSPECIFICATIONSYSTEM CONFIGURATIONHARDWARE REQUIREMENTS

Page 7: Computer project

PROCESSOR :INTEL PENTIUM 4 (OR)HIGHERRAM :512 MB & ABOVEHARD DISK DRIVE : 500 MB FREE SPACE OR ABOVEPRINTER : INK-JET PRINTERPEN DRIVE : 512MB.SOFTWARE REQUIREMENTSPROGRAMMING LANGUAGE : VISUAL PROGRAMMINGBACKEND :MS SQL SERVER-2005FRONT END :VISUAL BASIC.NETOPERATING SYSTEM : WINDOWS XP & HIGHER VERSIONSOFTWARE SPECIFICATIONVISUAL STUDIO . NETVisual Studio .NET is a complete set of development tools for building ASP Web applications XML Web services desktop applications mobile applicationsVisual Basic .NET, Visual C++ .NET, and Visual C# .NET all use thesame integrated development environment (IDE), which allows them to sharetools and facilitates in the creation of mixed-language solutions.Visual BasicVisual Basic has been updated to include many new and improved

Page 8: Computer project

language features that make it a powerful object-oriented programminglanguage. These features include inheritance, interfaces, and overloading,among others. Visual Basic also now supports structured exception handling,and custom attributes. In addition, Visual Basic supports multithreading.Multithreading is the ability to assign individual tasks to separate processingthreads.C#Visual C#, pronounced C sharp, is a new object-orientedprogramminglanguage that is an evolution of C and C++, providing a simple and type-safelanguage for developing applications.C++Managed Extensions for C++ and attributed programming are just someof the enhancements made to the C++ language. Managed Extensions simplifythe task of migrating existing C++ applications to the new .NET Framework.Attributes, like C++ keywords, are used in your source files and interpreted bythe compiler. Attributes are designed to provide a quick and efficient method tosimplify COM programming with Visual C++.JScript

Page 9: Computer project

JScript has been updated to be a class-based, object-oriented scriptinglanguage that maintains full backwards compatibility with previous versions ofJScript. JScript now provides class-based objects, typed variables, true compiledcode, and cross-language support through Common Language Specification(CLS) compliance. The primary role of JScript is development of Web siteswith ASP.NET and customization of applications with Script for the .NETFramework.Types of forms used in .NetWeb FormsWeb Forms are an ASP.NET technology that you use to createprogrammable Web pages. Web Forms render themselves as browsercompatibleHTML and script, which allows any browser on any platform toview the pages. Using Web Forms, you create Web pages by dragging anddropping controls onto the designer and then adding code, similar to the waythat you create Visual Basic formsInput designInput design is a part of overall system design, requires the very

Page 10: Computer project

careful analysis of the input data items. The goal of the input design is to makethe data entry easier, logical and free from errors. The user controls input data.The commonly used input, output devices are mouse, keyboardand the visual display unit. The well designed, well organized screen formatsare used to acquire the inputs. The data accepted is stored on database file.Our system is classified into subsystem such as Admission Staff Details Billing Consultation DetailsWard Details Ambulance Service Data ReportOutput DesignOutput is the most important and direct source of information the user.Efficient & intelligent output design improves the system relationshipswith the users and helps in decision-making. The output is collected in order tohelp the user to make a wise decision.Our project is yet to be implemented.SAMPLE CODINGSSAMPLE CODINGS :Login form:

Page 11: Computer project

Public Class LoginDim form1 As New mainmenuPrivate Sub OK_Click(ByVal sender As System.Object, ByVale As System.EventArgs) Handles OK.ClickIf PasswordTextBox.Text = "hospital" ThenMsgBox("Login Success", MsgBoxStyle.Information,"Hospital Management")PasswordTextBox.Text = ""Me.Hide()mainmenu.Show()ElseMsgBox("Login Failed", MsgBoxStyle.Critical,"Hospital Management")PasswordTextBox.Text = ""Me.Show()End IfEnd SubPrivate Sub Cancel_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Cancel.ClickMe.Close()End SubPrivate Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.ClickEndEnd SubEnd Class

Page 12: Computer project

Main Menu:Public Class mainmenuPrivate Sub ExitToolStripMenuItem_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)EndEnd SubPrivate Sub InpatientToolStripMenuItem_Click(ByVal senderAs System.Object, ByVal e As System.EventArgs) HandlesInpatientToolStripMenuItem.ClickMe.Hide()inpatient.Show()End SubPrivate Sub OutpatientToolStripMenuItem_Click(ByVal senderAs System.Object, ByVal e As System.EventArgs) HandlesOutpatientToolStripMenuItem.ClickMe.Hide()outpatient.Show()End SubPrivate Sub DoctorToolStripMenuItem_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)Me.Hide()doctper.Show()End Sub

Page 13: Computer project

Private Sub DoctorToolStripMenuItem1_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)Me.Hide()docpay.Show()End SubPrivate Sub DoctorToolStripMenuItem2_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)Me.Hide()doctsal.Show()End SubPrivate Sub PersonalDetailsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesPersonalDetailsToolStripMenuItem.ClickMe.Hide()doctper.Show()End SubPrivate Sub mainmenu_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.LoadEnd SubPrivate Sub DoctorToolStripMenuItem3_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)Me.Hide()doctate.Show()

Page 14: Computer project

End SubPrivate Sub DoctorToolStripMenuItem4_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)doctsif.Show()End SubPrivate Sub ODFormToolStripMenuItem_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesODFormToolStripMenuItem.ClickMe.Hide()doctsal.Show()End SubPrivate Sub PayrollDetailsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesPayrollDetailsToolStripMenuItem.ClickMe.Hide()docpay.Show()End SubPrivate Sub AttendanceDetailsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesAttendanceDetailsToolStripMenuItem.ClickMe.Hide()doctate.Show()End Sub

Page 15: Computer project

Private Sub ShiftDetailsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesShiftDetailsToolStripMenuItem.ClickMe.Hide()doctsif.Show()End SubPrivate Sub InpatientToolStripMenuItem1_Click(ByVal senderAs System.Object, ByVal e As System.EventArgs) HandlesInpatientToolStripMenuItem1.ClickMe.Hide()inpatbill.Show()End SubPrivate Sub OutpatientToolStripMenuItem1_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesOutpatientToolStripMenuItem1.ClickMe.Hide()outpatbill.Show()End SubPrivate Sub ConsultationToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesConsultationToolStripMenuItem.ClickMe.Hide()

Page 16: Computer project

consul.Show()End SubPrivate Sub WardDetailsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesWardDetailsToolStripMenuItem.ClickMe.Hide()ward.Show()End SubPrivate SubBillingAndPharmacyToolStripMenuItem_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesBillingAndPharmacyToolStripMenuItem.ClickEnd SubPrivate Sub AmbulanceServiceToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesAmbulanceServiceToolStripMenuItem.ClickMe.Hide()ambul.Show()End SubPrivate Sub ExitToolStripMenuItem1_Click(ByVal sender AsSystem.Object, ByVal e As System.EventArgs)Me.Hide()Login.Show()

Page 17: Computer project

End SubPrivate Sub ExitToolStripMenuItem_Click_1(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesExitToolStripMenuItem.ClickMe.Hide()Login.Show()End SubPrivate Sub InpatientsToolStripMenuItem_Click(ByVal senderAs System.Object, ByVal e As System.EventArgs) HandlesInpatientsToolStripMenuItem.Clickiptreport.Show()End SubPrivate Sub PharmacyToolStripMenuItem_Click(ByVal senderAs System.Object, ByVal e As System.EventArgs) HandlesPharmacyToolStripMenuItem.Clickiptbillview.Show()End SubPrivate Sub FeesCollectionsToolStripMenuItem_Click(ByValsender As System.Object, ByVal e As System.EventArgs) HandlesFeesCollectionsToolStripMenuItem.Clickoutbillview.Show()End Sub

Page 18: Computer project

End ClassInpatient Admission :Imports System.Data.OleDbPublic Class inpatientPrivate Sub Button2_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button2.ClickDim cmd As New OleDbCommandconn.open()Dim sql As String = "insert into ipt values('" &TextBox6.Text & "','" & TextBox5.Text & "','" & TextBox4.Text& "','" & RichTextBox4.Text & "','" & DateTimePicker1.Text &"','" & ComboBox1.Text & "','" & TextBox2.Text & "','" &TextBox3.Text & "','" & TextBox7.Text & "','" & TextBox8.Text& "','" & DateTimePicker2.Text & "')"cmd = New OleDbCommand(sql, conn)cmd.ExecuteReader()MsgBox("Record Inserted", MsgBoxStyleInformation,"Hospital Management")TextBox2.Text = ""TextBox3.Text = ""TextBox4.Text = ""RichTextBox4.Text = ""TextBox5.Text = ""

Page 19: Computer project

TextBox6.Text = ""TextBox7.Text = ""TextBox8.Text = ""ComboBox1.Text = ""conn.close()End SubPrivate Sub inpatient_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.LoadMe.ComboBox1.Items.Add("Male")Me.ComboBox1.Items.Add("Female")End SubPrivate Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.ClickMe.Hide()mainmenu.Show()End SubPrivate Sub Button4_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button4.Clickiptrecord.Show()End SubEnd ClassOutpatient Admission :Imports System.Data.OleDbPublic Class outpatient

Page 20: Computer project

Private Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.ClickMe.Hide()mainmenu.Show()End SubPrivate Sub Button2_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button2.ClickDim cmd As New OleDbCommandconn.open()Dim sql As String = "insert into opt values('" &TextBox6.Text & "','" & TextBox5.Text & "','" & TextBox4.Text& "','" & RichTextBox4.Text & "','" & DateTimePicker1.Text &"','" & ComboBox1.Text & "','" & TextBox2.Text & "','" &TextBox3.Text & "','" & TextBox7.Text & "','" & TextBox8.Text& "')"cmd = New OleDbCommand(sql, conn)cmd.ExecuteReader()MsgBox("Record Inserted", MsgBoxStyle.Information,"Hospital Management")TextBox2.Text = ""TextBox3.Text = ""

Page 21: Computer project

TextBox4.Text = ""RichTextBox4.Text = ""TextBox5.Text = ""TextBox6.Text = ""TextBox7.Text = ""TextBox8.Text = ""ComboBox1.Text = ""conn.close()End SubPrivate Sub outpatient_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.LoadMe.ComboBox1.Items.Add("Male")Me.ComboBox1.Items.Add("Female")End SubEnd ClassInpatient Bill :Imports System.DataImports System.Data.OleDbPublic Class inpatbillDim adp As New OleDbDataAdapterDim ds As New DataSetDim x As New IntegerDim cmd As New OleDbCommandDim dr As OleDbDataReaderPrivate Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.Click

Page 22: Computer project

Me.Hide()mainmenu.Show()End SubPrivate Sub Button2_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button2.Clickconn.open()cmd = New OleDbCommand("insert into inbill values('" &TextBox1.Text & "','" & ComboBox1.Text & "','" & TextBox3.Text& "','" & DateTimePicker2.Text & "','" & TextBox8.Text & "','"& TextBox9.Text & "','" & DateTimePicker1.Text & "','" &DateTimePicker2.Text & "','" & TextBox11.Text & "')", conn)cmd.ExecuteNonQuery()MsgBox("Bill Saved to Database", MsgBoxStyle.OkOnly,"Hospital Management")cmd.Dispose()TextBox1.Text = " "TextBox3.Text = " "TextBox8.Text = " "TextBox9.Text = " "TextBox10.Text = " "TextBox11.Text = " "ComboBox1.Text = " "

Page 23: Computer project

DateTimePicker1.Value = Now.DateDateTimePicker2.Value = Now.Dateconn.close()End SubPrivate Sub inpatbill_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.LoadComboBox1.TabIndex = 0TextBox9.TabIndex = 1TextBox10.TabIndex = 2TextBox11.TabIndex = 3conn.open()cmd = New OleDbCommand("select * from ipt", conn)dr = cmd.ExecuteReaderWhile (dr.Read)ComboBox1.Items.Add(dr(0).ToString)End Whilecmd.Dispose()cmd = New OleDbCommand("select max(bno) from inbill",conn)dr = cmd.ExecuteReaderIf dr.Read = True ThenTextBox1.Text = dr(0) + 1.ToStringElseTextBox1.Text = 1End Ifcmd.Dispose()

Page 24: Computer project

conn.close()End SubPrivate Sub ComboBox1_SelectedIndexChanged(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesComboBox1.SelectedIndexChangedconn.open()adp = New OleDbDataAdapter("select * from ipt wheremrdno=' " & ComboBox1.Text & "'", adpx)adp.Fill(ds, "ipt")TextBox3.Text = ds.Tables(0).Rows(0)(1).ToStringDateTimePicker1.Value =ds.Tables(0).Rows(0)(10).ToString()DateTimePicker2.Value = Now.Datex = DateTimePicker2.Value.Day -DateTimePicker1.Value.DayTextBox8.Text = x * 300conn.close()End SubPrivate Sub TextBox11_Enter(ByVal sender As Object, ByVale As System.EventArgs) Handles TextBox11.EnterTextBox11.Text = " "Dim x, y, z As New Integerx = TextBox8.Texty = TextBox9.Textz = TextBox10.Text

Page 25: Computer project

TextBox11.Text = x + y + zEnd SubPrivate Sub Button4_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button4.Clickiptbillview.Show()End SubEnd ClassOutpatient Bill :Imports System.Data.OleDbImports System.DataPublic Class outpatbillDim adp As New OleDbDataAdapterDim ds As New DataSetDim x As New IntegerDim cmd As New OleDbCommandDim dr As OleDbDataReaderPrivate Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.ClickMe.Hide()mainmenu.Show()End SubPrivate Sub Button2_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button2.Clickconn.open()

Page 26: Computer project

cmd = New OleDbCommand("insert into bill values('" &TextBox1.Text & "','" & ComboBox1.Text & "','" & TextBox2.Text& "','" & TextBox3.Text & "','" & DateTimePicker1.Text & "','"& TextBox7.Text & "')", conn)cmd.ExecuteNonQuery()MsgBox("Record inserted to Database",MsgBoxStyle.OkOnly, "Hospital Management")cleardata()conn.close()End SubSub cleardata()TextBox1.Text = NothingTextBox2.Text = NothingTextBox3.Text = NothingTextBox7.Text = NothingComboBox1.Text = NothingEnd SubPrivate Sub ComboBox1_SelectedIndexChanged(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesComboBox1.SelectedIndexChangedconn.open()adp = New OleDbDataAdapter("select * from opt wherehno=' " & ComboBox1.Text & "'", adpx)

Page 27: Computer project

adp.Fill(ds, "opt")TextBox2.Text = ds.Tables(0).Rows(0)(1).ToStringTextBox3.Text = ds.Tables(0).Rows(0)(9).ToStringconn.close()End SubPrivate Sub outpatbill_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.Loadconn.open()cmd = New OleDbCommand("select * from opt", conn)dr = cmd.ExecuteReaderWhile (dr.Read)ComboBox1.Items.Add(dr(0).ToString)End Whilecmd.Dispose()cmd = New OleDbCommand("select max(bno) from bill",conn)dr = cmd.ExecuteReaderIf dr.Read = True ThenTextBox1.Text = dr(0) + 1.ToStringElseTextBox1.Text = 1End Ifconn.close()cmd.Dispose()End Sub

Page 28: Computer project

Private Sub Button4_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button4.Clickcleardata()End SubPrivate Sub Button5_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button5.Clickoutbillview.Show()End SubEnd ClassInpatient Record Search:Imports System.DataImports System.Data.OleDbPublic Class iptrecordPrivate Sub Button1_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button1.Clickconn.open()TryDim sql As String = "select * from ipt where name= '" & TextBox1.Text & "'"Dim adp As OleDbDataAdapteradp = New OleDbDataAdapter(sql, adpx)Dim ds As DataSet = New DataSetadp.Fill(ds, "ipt")DataGridView1.DataSource = ds.Tables("ipt")

Page 29: Computer project

CatchMsgBox("Record not Found", , "HospitalManagement")End Tryconn.close()End SubPrivate Sub iptrecord_Load(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles MyBase.LoadTextBox1.Focus()End SubEnd ClassConsultation:Imports System.DataImports System.Data.OleDbPublic Class consulDim cmd As New OleDbCommandDim adp As New OleDbDataAdapterDim ds As New DataSetDim dr As OleDbDataReaderPrivate Sub Button5_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button5.ClickMe.Hide()mainmenu.Show()End SubPrivate Sub consul_Load(ByVal sender As System.Object,

Page 30: Computer project

ByVal e As System.EventArgs) Handles MyBase.LoadDataGridView1.Hide()conn.open()cmd = New OleDbCommand("select * from ipt", conn)dr = cmd.ExecuteReaderWhile (dr.Read)ComboBox1.Items.Add(dr(0).ToString)End Whilecmd.Dispose()End SubPrivate Sub ComboBox1_SelectedIndexChanged(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) HandlesComboBox1.SelectedIndexChangedadp = New OleDbDataAdapter("select * from ipt wheremrdno=' " & ComboBox1.Text & "'", adpx)adp.Fill(ds, "ipt")TextBox2.Text = ds.Tables(0).Rows(0)(1).ToStringTextBox3.Text = ds.Tables(0).Rows(0)(2).ToStringComboBox2.Text = ds.Tables(0).Rows(0)(5).ToStringDateTimePicker1.Value = Now.DateEnd SubPrivate Sub Button1_Click(ByVal sender As System.Object,

Page 31: Computer project

ByVal e As System.EventArgs) Handles Button1.Clickcmd = New OleDbCommand("insert into cons values('" &ComboBox1.Text & "','" & TextBox2.Text & "','" & TextBox3.Text& "','" & ComboBox2.Text & "','" & DateTimePicker1.Text &"','" & TextBox5.Text & "','" & TextBox6.Text & "')", conn)cmd.ExecuteNonQuery()MsgBox("Record inserted to Database",MsgBoxStyle.OkOnly, "Hospital Management")cleardata()cmd.Dispose()End SubSub cleardata()ComboBox1.Text = " "TextBox2.Text = " "TextBox3.Text = " "TextBox5.Text = " "TextBox6.Text = " "ComboBox2.Text = " "End SubPrivate Sub Button2_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button2.Clickcleardata()End Sub

Page 32: Computer project

Private Sub Button4_Click(ByVal sender As System.Object,ByVal e As System.EventArgs) Handles Button4.ClickDataGridView1.Show()TryDim sql As String = "select * from cons wheremrdno = '" & ComboBox1.Text & "'"Dim adp As OleDbDataAdapteradp = New OleDbDataAdapter(sql, adpx)Dim ds As DataSet = New DataSetadp.Fill(ds, "cons")DataGridView1.DataSource = ds.Tables("cons")CatchMsgBox("Record not Found", , "HospitalManagement")End Tryconn.close()End SubEnd ClassModule :Imports System.Data.OleDbModule Module1Public v As New OleDbConnectionPublic adpx As String = "Provider=SQLOLEDB;DataSource=ARULSOFT;Integrated Security=SSPI;InitialCatalog=hospital1"Public conn = New OleDbConnection("Provider=SQLOLEDB;DataSource=ARULSOFT;Integrated Security=SSPI;Initial

Page 33: Computer project

Catalog=hospital1")Public x As Integer = New Integer + 1Public Sub opendata()v.ConnectionString = "Provider=SQLOLEDB;DataSource=ARULSOFT;Integrated Security=SSPI;InitialCatalog=hospital1"v.Open()End SubPublic Sub closedata()v.Close()v = NothingEnd SubEnd ModuleBIBILIOGRAPHYBIBILIOGRAPHY1. OOP WITH MICROSOFT VISUAL BASIC.NET ANDMICROSOFT VISUAL C#.NET STEP BY STEP BYROBIN.A.REYNOLDS – HAERTLE – Microsoft Press 20022. THE BOOK OF VISUAL BASIC 2005. byMatthew MacDonald –NO STARCH PRESS3. VB.NET Developer’s Guide by Syngress Publishing, Inc.4. Visual Basic .NET How to Program Second Edition by Deitel &Associates, Inc.,5. VB.Net Language in a Nutshell by Steven Roman, Ron Petrusha –

Page 34: Computer project

O’Reilly 20016. Microsoft ADO.NET Step By Step – Microsoft Press 20057. Programming Microsoft Windows with Microsoft Visual Basic .NETby Charles Petsold 20028. PROGRAMMING MICROSOFT VISUAL BASIC.NET ByFrancesco Baleno – Microsoft Press 20049. Microsoft Visual Basic .NET Projects for the Classroom By Alfred CThompson Distributed byMainfunction.com10.Software Engineering , A PRACTITIONER’S APPROACH byRoger.S.Pressman,Ph.D. Fifth Edition11. Software Engineering Concepts, By Richard E.Fairley – TataMcGraw – Hill Publishing Company LimitedWEBILIOGRAPHYWEBILIOGRAPHY1. http://www.vbdotnetheaven.com/2. http://www.connectionstrings.com/