示例#1
0
    public static string[] getFirstName(string prefix)
    {
        DBHelperClass db      = new DBHelperClass();
        List <string> patient = new List <string>();

        if (prefix.IndexOf("'") > 0)
        {
            prefix = prefix.Replace("'", "''");
        }

        DataSet ds = db.selectData("select Patient_ID, LastName, FirstName from tblPatientMaster where FirstName like '%" + prefix + "%' OR LastName Like '%" + prefix + "%'");

        if (ds.Tables[0].Rows.Count > 0)
        {
            string name = "";
            for (int i = 0; i <= ds.Tables[0].Rows.Count - 1; i++)
            {
                name = ds.Tables[0].Rows[i]["LastName"].ToString();
                patient.Add(string.Format("{0}-{1}", name, ds.Tables[0].Rows[i]["Patient_ID"].ToString()));
            }
            name = "";
            for (int i = 0; i <= ds.Tables[0].Rows.Count - 1; i++)
            {
                name = ds.Tables[0].Rows[i]["FirstName"].ToString();
                patient.Add(string.Format("{0}-{1}", name, ds.Tables[0].Rows[i]["Patient_ID"].ToString()));
            }
        }

        return(patient.ToArray());
    }
    protected void btnSave_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            string         SP    = "";
            SqlParameter[] param = null;

            if (Request["id"] != null)
            {
                param = new SqlParameter[10];
                SP    = "update tbl_designation set Designation='" + txtDesignation.Text + "' where id=" + Request["id"];
            }
            else
            {
                param = new SqlParameter[10];
                SP    = "insert into tbl_designation values('" + txtDesignation.Text + "')";
            }
            int val = db.executeQuery(SP);

            if (val > 0)
            {
                Response.Redirect("ViewDesignation.aspx");
            }
        }
        catch (Exception ex)
        {
        }
    }
示例#3
0
    private void bindLocation()
    {
        DataSet       ds = new DataSet();
        DBHelperClass db = new DBHelperClass();

        string query = "select Location,Location_ID from tblLocations ";

        if (!string.IsNullOrEmpty(Session["Locations"].ToString()))
        {
            query = query + " where Location_ID in (" + Session["Locations"] + ")";
        }
        query = query + " Order By Location";

        ds = db.selectData(query);
        if (ds.Tables[0].Rows.Count > 0)
        {
            ddl_location.DataValueField = "Location_ID";
            ddl_location.DataTextField  = "Location";

            ddl_location.DataSource = ds;
            ddl_location.DataBind();

            ddl_location.Items.Insert(0, new ListItem("-- All --", "0"));
        }
    }
    protected void lnkDelete_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            LinkButton     lnkdelete = sender as LinkButton;
            string         SP        = "nusp_Delete_DiagCodes";
            SqlParameter[] param     = new SqlParameter[1];



            param[0] = new SqlParameter("@DiagCode_ID", lnkdelete.CommandArgument);


            int val = db.executeSP(SP, param);

            if (val > 0)
            {
                bindDiagCodeDetails(1);
                divSuccess.Attributes.Add("style", "display:block");
                divfail.Attributes.Add("style", "display:none");
            }
            else
            {
                divSuccess.Attributes.Add("style", "display:none");
                divfail.Attributes.Add("style", "display:block");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#5
0
    private void bindMCODE(string bpart, string position = "")
    {
        try
        {
            string query = "select * from tblProcedures";
            if (!string.IsNullOrEmpty(bpart) && !string.IsNullOrEmpty(position))
            {
                query = query + " where BodyPart='" + bpart + "' and position='" + position + "' ";
            }
            else if (!string.IsNullOrEmpty(bpart))
            {
                query = query + " where BodyPart='" + bpart + "' ";
            }

            DataSet ds = new DBHelperClass().selectData(query);

            ddlProcSchedule.DataSource = ds;
            ddlProcSchedule.DataBind();

            ddlProcSchedule.Items.Insert(0, new ListItem("Please Select", "0"));

            chkProcExe.DataSource = ds;
            chkProcExe.DataBind();
        }
        catch (Exception ex)
        {
        }
    }
示例#6
0
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        try
        {
            string         SP    = "nusp_Delete_PatientMaster";
            SqlParameter[] param = new SqlParameter[1];



            param[0] = new SqlParameter("@Patient_ID", Request["id"].ToString());


            int val = new DBHelperClass().executeSP(SP, param);

            if (val > 0)
            {
                Response.Redirect("ViewPatientMaster.aspx");
            }
            else
            {
                divfail.Attributes.Add("style", "display:block");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#7
0
    protected void lnkDelete_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            LinkButton lnkdelete = sender as LinkButton;
            string     SP        = "delete from tbl_designation where id=" + lnkdelete.CommandArgument;



            int val = db.executeQuery(SP);

            if (val > 0)
            {
                bindGroupsDetails(1);
                divSuccess.Attributes.Add("style", "display:block");
                divfail.Attributes.Add("style", "display:none");
            }
            else
            {
                divSuccess.Attributes.Add("style", "display:none");
                divfail.Attributes.Add("style", "display:block");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#8
0
 protected void Page_Load(object sender, EventArgs e)
 {
     Session["PageName"] = "Neck";
     if (Session["uname"] == null)
     {
         Response.Redirect("Login.aspx");
     }
     if (!IsPostBack)
     {
         checkTP();
         if (Session["PatientIE_ID"] != null && Session["patientFUId"] != null)
         {
             BindROM();
             bindDropdown();
             _CurIEid = Session["PatientIE_ID"].ToString();
             _FuId    = Session["patientFUId"].ToString();
             SqlConnection  cn    = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString);
             DBHelperClass  db    = new DBHelperClass();
             string         query = ("select count(*) as FuCount FROM tblFUbpNeck WHERE PatientFU_ID = " + _FuId + "");
             SqlCommand     cm    = new SqlCommand(query, cn);
             SqlDataAdapter Fuda  = new SqlDataAdapter(cm);
             cn.Open();
             DataSet FUds = new DataSet();
             Fuda.Fill(FUds);
             cn.Close();
             string         query1 = ("select count(*) as IECount FROM tblbpNeck WHERE PatientIE_ID= " + _CurIEid + "");
             SqlCommand     cm1    = new SqlCommand(query1, cn);
             SqlDataAdapter IEda   = new SqlDataAdapter(cm1);
             cn.Open();
             DataSet IEds = new DataSet();
             IEda.Fill(IEds);
             cn.Close();
             DataRow FUrw = FUds.Tables[0].AsEnumerable().FirstOrDefault(tt => tt.Field <int>("FuCount") == 0);
             DataRow IErw = IEds.Tables[0].AsEnumerable().FirstOrDefault(tt => tt.Field <int>("IECount") == 0);
             if (FUrw == null)
             {
                 PopulateUI(_FuId);
                 BindDCDataGrid();
                 BindDataGrid();
             }
             else if (IErw == null)
             {
                 PopulateIEUI(_CurIEid);
                 BindDCDataGrid();
                 BindDataGrid();
             }
             else
             {
                 PopulateUIDefaults();
                 BindDataGrid();
             }
         }
         else
         {
             Response.Redirect("EditFU.aspx");
         }
     }
     Logger.Info(Session["uname"].ToString() + "- Visited in  EditFuNeck for -" + Convert.ToString(Session["LastNameFUEdit"]) + Convert.ToString(Session["FirstNameFUEdit"]) + "-" + DateTime.Now);
 }
示例#9
0
    public void Reschedules(string id)
    {
        DBHelperClass dBHelper = new DBHelperClass();
        string        query    = "update tblProceduresDetail set Scheduled=null where ProcedureDetail_ID=" + id;

        dBHelper.executeQuery(query);
        BindProcudureList();
    }
示例#10
0
    public void PopulateUI(string fuid)
    {
        string sProvider = ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString;
        string SqlStr    = "";

        oSQLConn.ConnectionString = sProvider;
        oSQLConn.Open();
        SqlStr = "Select * from tblFUbpNeck WHERE PatientFU_ID = " + fuid;
        SqlDataAdapter    sqlAdapt      = new SqlDataAdapter(SqlStr, oSQLConn);
        SqlCommandBuilder sqlCmdBuilder = new SqlCommandBuilder(sqlAdapt);
        DataTable         sqlTbl        = new DataTable();

        sqlAdapt.Fill(sqlTbl);
        DataRow TblRow;

        if (sqlTbl.Rows.Count > 0)
        {
            _fldPop = true;
            TblRow  = sqlTbl.Rows[0];

            txtFreeFormA.Text = TblRow["FreeFormA"].ToString().Trim().Replace("      ", string.Empty);

            CF.InnerHtml = sqlTbl.Rows[0]["CCvalue"].ToString();


            divPE.InnerHtml = sqlTbl.Rows[0]["PEvalue"].ToString();

            hdorgvalPE.Value = sqlTbl.Rows[0]["PEvalueoriginal"].ToString();

            int val = checkTP();

            ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), "checkTP(" + val.ToString() + ");bindSidesVal('" + sqlTbl.Rows[0]["PESides"].ToString() + "','" + sqlTbl.Rows[0]["PESidesText"].ToString() + "');", true);


            SqlConnection  cn1   = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString);
            DBHelperClass  db    = new DBHelperClass();
            string         query = ("select PatientFU_ID FROM tblFUbpNeck WHERE PatientFU_ID = " + _FuId + "");
            SqlCommand     cm    = new SqlCommand(query, cn1);
            SqlDataAdapter Fuda  = new SqlDataAdapter(cm);
            cn1.Open();
            DataSet FUds = new DataSet();
            Fuda.Fill(FUds);


            //txtFreeForm.Text = TblRow["FreeForm"].ToString().Trim();
            //txtFreeFormCC.Text = TblRow["FreeFormCC"].ToString().Trim();
            txtFreeFormA.Text = TblRow["FreeFormA"].ToString().Trim().Replace("      ", string.Empty);
            txtFreeFormP.Text = TblRow["FreeFormP"].ToString().Trim();

            //txtWorseOtherText.Text = TblRow["WorseOther"].ToString().Trim();
            _fldPop = false;
            cn1.Close();
        }
        sqlTbl.Dispose();
        sqlCmdBuilder.Dispose();
        sqlAdapt.Dispose();
        oSQLConn.Close();
    }
示例#11
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            string         SP    = "";
            SqlParameter[] param = null;

            if (Request["id"] != null)
            {
                param = new SqlParameter[11];
                SP    = "nusp_Update_InsCos";
            }
            else
            {
                param = new SqlParameter[11];
                SP    = "nusp_Insert_InsCos";
            }

            param[0] = new SqlParameter("@InsCo", txtInco.Text);
            param[1] = new SqlParameter("@SetAsDefault", chkSetDefault.Checked);

            param[2] = new SqlParameter("@Address1", txtAddress1.Text);


            param[3] = new SqlParameter("@City", txtCity.Text);
            param[4] = new SqlParameter("@State", txtState.Text);
            param[5] = new SqlParameter("@Zip", txtZip.Text);
            param[6] = new SqlParameter("@EmailAddress", txtEmail.Text);

            param[7] = new SqlParameter("@Telephone", txtPhone.Text);
            param[8] = new SqlParameter("@ContactPerson", txtContacts.Text);
            param[9] = new SqlParameter("@Address2", txtAddress2.Text);


            if (Request["id"] != null)
            {
                param[10] = new SqlParameter("@InsCo_ID", Request["id"]);
            }
            else
            {
                param[10] = new SqlParameter("@CreatedBy", "Admin");
            }


            int val = db.executeSP(SP, param);

            if (val > 0)
            {
                Response.Redirect("ViewInsCo.aspx");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#12
0
 public void TransferToExecute(string id, string sDate)
 {
     if (!string.IsNullOrEmpty(sDate))
     {
         DBHelperClass dBHelper = new DBHelperClass();
         string        query    = "update tblProceduresDetail set Executed='" + sDate + "',Scheduled=null where ProcedureDetail_ID=" + id;
         dBHelper.executeQuery(query);
     }
 }
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        DBHelperClass db    = new DBHelperClass();
        Button        btn   = sender as Button;
        string        query = "delete from tblPatientDocument where Document_ID=" + btn.CommandArgument;

        db.executeQuery(query);
        getData();
    }
示例#14
0
    private void savePatientData(DataRow dataRow)
    {
        DBHelperClass helperClass = new DBHelperClass();

        SqlParameter[] param = null;
        string         sp    = "";

        if (dataRow["ID"].ToString() == "")
        {
            param = new SqlParameter[27];
            sp    = "nusp_import_patientdata";
        }
        else
        {
            param = new SqlParameter[28];
            sp    = "nusp_import_update_patientdata";
        }

        param[0]  = new SqlParameter("@location", dataRow["Location"].ToString());
        param[1]  = new SqlParameter("@DOS", dataRow["DOS"].ToString());
        param[2]  = new SqlParameter("@DOA", dataRow["DOA"].ToString());
        param[3]  = new SqlParameter("@lastname", dataRow["Last Name"].ToString());
        param[4]  = new SqlParameter("@firstname", dataRow["First Name"].ToString());
        param[5]  = new SqlParameter("@middlename", dataRow["ML"].ToString());
        param[6]  = new SqlParameter("@sex", dataRow["Sex"].ToString());
        param[7]  = new SqlParameter("@DOB", dataRow["DOB"].ToString());
        param[8]  = new SqlParameter("@SSN", dataRow["SSN"].ToString());
        param[9]  = new SqlParameter("@home_ph", dataRow["Home Ph"].ToString());
        param[10] = new SqlParameter("@work_ph", dataRow["Work Ph"].ToString());
        param[11] = new SqlParameter("@mobile", dataRow["Mobile"].ToString());
        param[12] = new SqlParameter("@address", dataRow["Address"].ToString());
        param[13] = new SqlParameter("@city", dataRow["City"].ToString());
        param[14] = new SqlParameter("@state", dataRow["State"].ToString());
        param[15] = new SqlParameter("@zip", dataRow["Zip"].ToString());
        param[16] = new SqlParameter("@ins_co", dataRow["Insurance_Co"].ToString());
        param[17] = new SqlParameter("@claim", dataRow["Claim #"].ToString());
        param[18] = new SqlParameter("@policy_no", dataRow["Policy #"].ToString());
        param[19] = new SqlParameter("@attorney_name", dataRow["Attorney Name"].ToString());
        param[20] = new SqlParameter("@attorney_ph", dataRow["Attorney Ph"].ToString());
        param[21] = new SqlParameter("@case_type", dataRow["Case Type"].ToString());
        param[22] = new SqlParameter("@wcb_group", dataRow["WCB Group"].ToString());
        param[23] = new SqlParameter("@ma_provider", dataRow["MA & Providers"].ToString());
        param[24] = new SqlParameter("@adjuster", dataRow["Adjuster"].ToString());
        param[25] = new SqlParameter("@adjuster_ph", dataRow["Adjuster Ph"].ToString());
        param[26] = new SqlParameter("@ext", dataRow["Ext"].ToString());

        if (dataRow["ID"].ToString() != "")
        {
            param[27] = new SqlParameter("@PIE_ID", dataRow["ID"].ToString());
        }


        int val = helperClass.executeSP(sp, param);
    }
示例#15
0
    protected void Page_Load(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        if (Session["log"] != null)
        {
            db.logDetailtbl(Convert.ToInt32(Session["log"].ToString()), "LogOut", Convert.ToString(System.DateTime.Now));
            Logger.Info(Session["UserId"].ToString() + Session["uname"].ToString() + "- Logged OUT at" + DateTime.Now);
        }
        Session.Abandon();

        Response.Redirect("Login.aspx");
    }
示例#16
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            string         SP    = "";
            SqlParameter[] param = null;

            if (Request["id"] != null)
            {
                param = new SqlParameter[5];
                SP    = "[nusp_Update_DiagCodes]";
            }
            else
            {
                param = new SqlParameter[5];
                SP    = "nusp_Insert_DiagCodes";
            }

            param[0] = new SqlParameter("@BodyPart", txtBodyPart.Text);
            param[1] = new SqlParameter("@DiagCode", txtDiagCode.Text);
            param[2] = new SqlParameter("@Description", txtDescription.Text);
            param[3] = new SqlParameter("@PreSelect", chkPreSelect.Checked);



            if (Request["id"] != null)
            {
                param[4] = new SqlParameter("@DiagCode_ID", Request["id"]);
            }
            else
            {
                param[4] = new SqlParameter("@CreatedBy", "Admin");
            }


            int val = db.executeSP(SP, param);

            if (val > 0)
            {
                Response.Redirect("ViewDiagCodes.aspx");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#17
0
 protected void Page_Load(object sender, EventArgs e)
 {
     Session["PageName"] = "Midback";
     if (Session["uname"] == null)
     {
         Response.Redirect("Login.aspx");
     }
     if (!IsPostBack)
     {
         checkTP();
         if (Session["PatientIE_ID"] != null)
         {
             bindDropdown();
             // BindROM();
             _CurIEid = Session["PatientIE_ID"].ToString();
             SqlConnection  cn    = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString);
             DBHelperClass  db    = new DBHelperClass();
             string         query = ("select count(*) as count1 FROM tblbpMidBack WHERE PatientIE_ID= " + Session["PatientIE_ID"].ToString() + "");
             SqlCommand     cm    = new SqlCommand(query, cn);
             SqlDataAdapter da    = new SqlDataAdapter(cm);
             cn.Open();
             DataSet ds = new DataSet();
             da.Fill(ds);
             cn.Close();
             DataRow rw = ds.Tables[0].AsEnumerable().FirstOrDefault(tt => tt.Field <int>("count1") == 0);
             if (rw != null)
             {
                 // row exists
                 PopulateUIDefaults();
                 BindDataGrid();
                 bindCC();
                 bindPE();
             }
             else
             {
                 _CurIEid = Session["PatientIE_ID"].ToString();
                 PopulateUI(_CurIEid);
                 BindDataGrid();
             }
         }
         else
         {
             Response.Redirect("Page1.aspx");
         }
         bindgridPoup();
     }
     BindDCDataGrid();
     Logger.Info(Session["uname"].ToString() + "- Visited in  Midback for -" + Convert.ToString(Session["LastNameIE"]) + Convert.ToString(Session["FirstNameIE"]) + "-" + DateTime.Now);
 }
示例#18
0
    private void bindBodyPart()
    {
        try
        {
            DataTable ds = new DBHelperClass().GetallBodyparts();

            ddlbodypart.DataSource = ds;
            ddlbodypart.DataBind();

            ddlbodypart.Items.Insert(0, new ListItem("Please Select", "0"));
        }
        catch (Exception ex)
        {
        }
    }
    private void getPatietDetail()
    {
        try
        {
            DataTable dt = new DBHelperClass().selectDatatable("select Patient_ID,DOA from tblPatientIE where PatientIE_ID=" + Request["PIEID"].ToString());

            if (dt != null && dt.Rows.Count > 0)
            {
                ViewState["pid"] = dt.Rows[0]["Patient_ID"].ToString();
                ViewState["doa"] = dt.Rows[0]["DOA"].ToString();
            }
        }
        catch (Exception ex)
        {
        }
    }
示例#20
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        string        query = "select Password from tblUserMaster where (LoginID=@uname or eMailID=@uname)";
        SqlConnection cn    = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString);

        SqlCommand cm = new SqlCommand(query, cn);

        cm.Parameters.AddWithValue("@uname", txt_uname.Text);


        SqlDataAdapter da = new SqlDataAdapter(cm);
        DataSet        ds = new DataSet();

        da.Fill(ds);

        if (ds.Tables[0].Rows.Count > 0)
        {
            if (ds.Tables[0].Rows[0]["Password"].ToString() == txt_pass.Text)
            {
                //Change the password and redirect next page
                DBHelperClass db = new DBHelperClass();

                query = "UPDATE tblUserMaster SET Password = '******' WHERE LoginID = '" + txt_uname.Text.ToString() + "'";

                int val = db.executeQuery(query);

                if (val > 0)
                {
                    Session["uname"]     = txt_uname.Text;
                    lblMessage.InnerHtml = "Password has been changed successfuly.";
                    lblMessage.Attributes.Add("style", "color:green");
                    upMessage.Update();
                    ScriptManager.RegisterClientScriptBlock(Page, Page.GetType(), Guid.NewGuid().ToString(), "openPopup('mymodelmessage')", true);
                    Response.Redirect("PatientIntakeList.aspx");
                }
            }
            else
            {
                lblmess.Attributes.Add("style", "display:block");
            }
        }
        else
        {
            lblmess.Attributes.Add("style", "display:block");
        }
    }
示例#21
0
    protected void lnkDelete_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            LinkButton lnkdelete = sender as LinkButton;



            Response.Redirect("DeleteConfirmMessage.aspx?id=" + lnkdelete.CommandArgument);
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
    protected void btnPreview_Click(object sender, EventArgs e)
    {
        DBHelperClass db    = new DBHelperClass();
        Button        btn   = sender as Button;
        string        query = "select * from tblPatientDocument where Document_ID=" + btn.CommandArgument;
        DataSet       ds    = db.selectData(query);

        string path = @"https://docs.google.com/viewer?url=#url&embedded=true";
        string url  = "http://aeiuat.dynns.com:82/V3_Test" + ds.Tables[0].Rows[0]["path"].ToString().Replace("~", "");

        path = path.Replace("#url", url);
        //iframeDocument.Src = path;

        // iframeDocument.Src = @"https://docs.google.com/viewer?url=http://infolab.stanford.edu/pub/papers/google.pdf&embedded=true";

        // ClientScript.RegisterStartupScript(this.GetType(), "Popup", "openPopup();", true);
    }
示例#23
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            string         SP    = "";
            SqlParameter[] param = null;

            if (Request["id"] != null)
            {
                param = new SqlParameter[2];
                SP    = "[nusp_Update_Medicine]";
            }
            else
            {
                param = new SqlParameter[2];
                SP    = "nusp_Insert_Medicine";
            }

            param[0] = new SqlParameter("@Medicine", txtMedicine.Text);



            if (Request["id"] != null)
            {
                param[1] = new SqlParameter("@Medicine_ID", Request["id"]);
            }
            else
            {
                param[1] = new SqlParameter("@CreatedBy", "Admin");
            }


            int val = db.executeSP(SP, param);

            if (val > 0)
            {
                Response.Redirect("ViewMedicine.aspx");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#24
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            string query = "", strmcode = "", position = "";


            for (int i = 0; i < chkProcExe.Items.Count; i++)
            {
                if (chkProcExe.Items[i].Selected)
                {
                    strmcode = strmcode + "," + chkProcExe.Items[i].Text;
                }
            }

            if (ddlbodypart.SelectedValue.ToLower() != "neck" || ddlbodypart.SelectedValue.ToLower() != "midback" || ddlbodypart.SelectedValue.ToLower() != "lowback")
            {
                position = ddlposition.SelectedValue;
            }

            if (Request["id"] == null)
            {
                query = "insert into tblProcedureStatus values('" + ddlProcSchedule.SelectedValue + "','" + strmcode.TrimStart(',') + "','" + ddlbodypart.SelectedValue + "','" + position + "')";
            }
            else
            {
                query = " update tblProcedureStatus set Procedures='" + ddlProcSchedule.SelectedValue + "',PreRequest='" + strmcode.TrimStart(',') + "',BodyPart='" + ddlbodypart.SelectedValue + "',Position='" + ddlposition.SelectedValue + "' where id=" + Request["id"];
            }

            int val = db.executeQuery(query);
            if (val > 0)
            {
                Response.Redirect("ViewProcConstraint.aspx");
            }
        }
        catch (Exception ex)
        {
            log.Error(ex.Message);
        }
    }
示例#25
0
    protected void lnkDelete_Click(object sender, EventArgs e)
    {
        DBHelperClass db = new DBHelperClass();

        try
        {
            LinkButton lnkdelete = sender as LinkButton;
            string     SP        = "delete from tblUserMaster where User_ID=" + lnkdelete.CommandArgument;

            db.executeQuery(SP);

            //if (val > 0)
            //{
            BindUserDetails(1);
            divSuccess.Attributes.Add("style", "display:block");
            divfail.Attributes.Add("style", "display:none");
        }
        catch (Exception ex)
        {
            divSuccess.Attributes.Add("style", "display:none");
            divfail.Attributes.Add("style", "display:block");
            log.Error(ex.Message);
        }
    }
示例#26
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Position            = Request.QueryString["P"];
        Session["PageName"] = "Elbow";
        if (Session["uname"] == null)
        {
            Response.Redirect("Login.aspx");
        }
        if (!IsPostBack)
        {
            if (Session["PatientIE_ID"] != null)
            {
                bindDropdown();
                BindROM();
                _CurIEid = Session["PatientIE_ID"].ToString();
                SqlConnection  cn    = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString);
                DBHelperClass  db    = new DBHelperClass();
                string         query = ("select count(*) as count1 FROM tblbpElbow WHERE PatientIE_ID= " + Session["PatientIE_ID"].ToString() + "");
                SqlCommand     cm    = new SqlCommand(query, cn);
                SqlDataAdapter da    = new SqlDataAdapter(cm);
                cn.Open();
                DataSet ds = new DataSet();
                da.Fill(ds);
                cn.Close();
                DataRow rw = ds.Tables[0].AsEnumerable().FirstOrDefault(tt => tt.Field <int>("count1") == 0);
                if (rw != null)
                {
                    // row exists
                    PopulateUIDefaults();
                    BindDataGrid();
                    bindCC(Position);
                    bindPE(Position);
                }
                else
                {
                    PopulateUI(_CurIEid);
                    BindDataGrid();
                }
                if (Position != "")
                {
                    switch (Position)
                    {
                    case "L":

                        txtExtension1.ReadOnly  = false;
                        txtFlex1.ReadOnly       = false;
                        txtSupination1.ReadOnly = false;
                        txtPronation1.ReadOnly  = false;
                        //Left textbox
                        txtExtension2.ReadOnly  = true;
                        txtFlex2.ReadOnly       = true;
                        txtSupination2.ReadOnly = true;
                        txtPronation2.ReadOnly  = true;
                        break;

                    case "R":

                        txtExtension1.ReadOnly  = true;
                        txtFlex1.ReadOnly       = true;
                        txtSupination1.ReadOnly = true;
                        txtPronation1.ReadOnly  = true;
                        //Left textbox
                        txtExtension2.ReadOnly  = false;
                        txtFlex2.ReadOnly       = false;
                        txtSupination2.ReadOnly = false;
                        txtPronation2.ReadOnly  = false;
                        break;

                    case "B":

                        txtExtension1.ReadOnly  = false;
                        txtFlex1.ReadOnly       = false;
                        txtSupination1.ReadOnly = false;
                        txtPronation1.ReadOnly  = false;
                        //Left textbox
                        txtExtension2.ReadOnly  = false;
                        txtFlex2.ReadOnly       = false;
                        txtSupination2.ReadOnly = false;
                        txtPronation2.ReadOnly  = false;
                        break;
                    }
                }
            }
            else
            {
                Response.Redirect("Page1.aspx");
            }
        }
        BindDCDataGrid();
        Logger.Info(Session["uname"].ToString() + "- Visited in  Elbow for -" + Convert.ToString(Session["LastNameIE"]) + Convert.ToString(Session["FirstNameIE"]) + "-" + DateTime.Now);
    }
示例#27
0
    public void bindPOC()
    {
        try
        {
            DBHelperClass db = new DBHelperClass();


            string SqlStr = @"Select 
                        CASE 
                              WHEN p.Requested is not null 
                               THEN Convert(varchar,p.ProcedureDetail_ID) +'_R'
                              ELSE 
                                case when p.Scheduled is not null
                                    THEN  Convert(varchar,p.ProcedureDetail_ID) +'_S'
                                ELSE
                                   CASE
                                        WHEN p.Executed is not null
                                        THEN Convert(varchar,p.ProcedureDetail_ID) +'_E'
                              END  END END as ID, 
                        CASE 
                              WHEN p.Requested is not null 
                               THEN p.Heading
                              ELSE 
                                case when p.Scheduled is not null
                                    THEN p.S_Heading
                                ELSE
                                   CASE
                                        WHEN p.Executed is not null
                                        THEN p.E_Heading
                              END  END END as Heading, 
                              CASE 
                              WHEN p.Requested is not null 
                               THEN p.PDesc
                              ELSE 
                                case when p.Scheduled is not null
                                    THEN p.S_PDesc
                                ELSE
                                   CASE
                                        WHEN p.Executed is not null
                                        THEN p.E_PDesc
                              END  END END as PDesc,
 CASE 
                              WHEN p.Requested is not null 
                               THEN p.Requested
                              ELSE 
                                case when p.Scheduled is not null
                                    THEN p.Scheduled
                                ELSE
                                   CASE
                                        WHEN p.Executed is not null
                                        THEN p.Executed
                              END  END END as PDate,
BodyPart
                             -- ,p.Requested,p.Heading RequestedHeading,p.Scheduled,p.S_Heading ScheduledHeading,p.Executed,p.E_Heading ExecutedHeading
                         from tblProceduresDetail p WHERE PatientIE_ID = " + Session["PatientIE_ID"].ToString() + "  and IsConsidered=0  Order By BodyPart,Heading";;


            DataSet dsPOC = db.selectData(SqlStr);


            if (dsPOC != null && dsPOC.Tables[0].Rows.Count > 0)
            {
                repSummery.DataSource = dsPOC;
                repSummery.DataBind();
            }
            else
            {
                repSummery.DataSource = null;
                repSummery.DataBind();
            }
        }
        catch (Exception ex)
        {
        }
    }
示例#28
0
    protected void btnupload_mul_Click(object sender, EventArgs e)
    {
        DBHelperClass dBHelperClass = new DBHelperClass();
        DataSet       dataSet = new DataSet();
        string        fname = "", lname = "", doa = "";


        foreach (HttpPostedFile postedFile in fupmul.PostedFiles)
        {
            //string[] fileName = Path.GetFileName(postedFile.FileName).Split(',');
            string fileName = Path.GetFileName(postedFile.FileName);
            string msg      = "";
            try
            {
                Regex re = new Regex(@"\d+");
                Match m  = re.Match(fileName);
                if (m.Success)
                {
                    string   file = fileName.Substring(0, m.Index);
                    string[] str  = file.Split(',');
                    // lblResults.Text = string.Format("RegEx found " + m.Value + " at position " + m.Index.ToString() + " character in string is " + file + " fname: " + str[1] + ",LastName:" + str[0]);
                    lname = str[0];

                    if (str[1].Contains("_"))
                    {
                        fname = str[1].Split('_')[0];
                    }
                    else
                    {
                        fname = str[1];
                    }

                    file = fileName;
                    str  = file.Split('_');
                    if (str.Length > 2)
                    {
                        doa = str[str.Length - 1].ToLower().Split('.')[0];
                    }
                }
                else
                {
                    string[] str = fileName.Split('_');
                    fname = str[0].Split(',')[1];
                    lname = str[0].Split(',')[0];
                }

                doa = CommonConvert.DateformatDOA(doa);
                doa = CommonConvert.DateFormat(doa);

                string[] strfname = fname.TrimStart().Split(' ');
                fname   = strfname[0];
                dataSet = dBHelperClass.selectData("select Patient_ID from tblPatientMaster where LastName='" + lname.Trim().TrimStart() + "' and FirstName='" + fname.Trim().TrimStart() + "'");

                if (dataSet != null && dataSet.Tables[0].Rows.Count > 0)
                {
                    string patientid = dataSet.Tables[0].Rows[0][0].ToString();

                    string upload_folder_path = "~/PatientDocument/" + patientid;

                    if (!Directory.Exists(upload_folder_path))
                    {
                        Directory.CreateDirectory(Server.MapPath(upload_folder_path));
                    }

                    postedFile.SaveAs(System.IO.Path.Combine(Server.MapPath(upload_folder_path), fileName));

                    sb.Append("<p>File Name : " + fileName + "  patientid:" + patientid + "     Status : Uploaded </p>");
                    sb.Append(Environment.NewLine);
                    Logger.Info("File Name : " + fileName + "  patientid:" + patientid + "     Status : Uploaded");

                    //string filename = System.DateTime.Now.Millisecond.ToString() + "_" + fileName;
                    if (checkName(fileName, patientid) == false)
                    {
                        string filename = fileName;
                        string query    = "insert into tblPatientDocument values('" + filename + "','" + System.DateTime.Now.ToString() + "','" + upload_folder_path + "/" + filename + "'," + patientid + ",'" + doa + "')";

                        dBHelperClass.executeQuery(query);
                    }
                }
                else
                {
                    sb.Append("<p style='color:red'> File Name : " + fileName + "     Status : Not Uploaded</p>");
                    sb.Append(Environment.NewLine);
                    Logger.Info("File Name : " + fileName + "     Status : Not Uploaded");
                }
            }
            catch (Exception ex)
            {
                sb.Append("<p style='color:red'>File Name : " + fileName + "     Status : Not Uploaded </p>");
                Logger.Error("File Name : " + fileName + "       Status : Not Uploaded \n");
            }
            lblResult.InnerHtml = sb.ToString();
        }
    }
示例#29
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        try
        {
            DBHelperClass db    = new DBHelperClass();
            string        query = "";

            //query = "update  tblPatientIEDetailPage1 set FreeForm='" + txt_FreeForm.Text + "' where PatientIE_ID=" + Session["PatientIE_ID"].ToString();


            //int val = db.executeQuery(query);

            //if (val > 0)
            //{


            query = "select top 1 * from tblPatientIEDetailPage2 where PatientIE_ID=" + Session["PatientIE_ID"].ToString();
            DataSet ds = db.selectData(query);
            if (ds.Tables[0].Rows.Count == 0)
            {
                query = "insert into tblPatientIEDetailPage2 (";
                query = query + "intactexcept,LEdtr,DTRtricepsRight,DTRtricepsLeft,DTRBicepsRight,DTRBicepsLeft,DTRBrachioRight,DTRBrachioLeft,UEdtr,DTRKneeLeft,DTRKneeRight,DTRAnkleLeft,DTRAnkleRight,Sensory,PinPrick,Lighttouch,";
                query = query + "LEsen,LEL3Right,LEL3Left,LEL4Right,LEL4Left,LEL5Right,LEL5Left,LES1Left,LES1Right,LELumberParaspinalsLeft,LELumberParaspinalsRight,UEsen,UEC5Left,UEC5Right,UEC6Left,UEC6Right,UEC7Left,UEC7Right,UEC8Left,UEC8Right,UET1Right,UET1Left,UECervicalParaspinalsRight,UECervicalParaspinalsLeft,";
                query = query + "LEmmst,LEHipFlexionRight,LEHipFlexionLeft,LEHipAbductionRight,LEHipAbductionLeft,LEKneeExtensionRight,LEKneeExtensionLeft,LEKneeFlexionRight,LEKneeFlexionLeft,LEAnkleDorsiRight,LEAnkleDorsiLeft,LEAnklePlantarRight,LEAnklePlantarLeft,LEAnkleExtensorRight,LEAnkleExtensorLeft,";
                query = query + "UEmmst,UEShoulderAbductionRight,UEShoulderAbductionLeft,UEShoulderFlexionRight,UEShoulderFlexionLeft,UEElbowExtensionRight,UEElbowExtensionLeft,UEElbowFlexionRight,UEElbowFlexionLeft,UEElbowSupinationRight,UEElbowSupinationLeft,UEElbowPronationRight,UEElbowPronationLeft,UEWristFlexionRight,UEWristFlexionLeft,UEWristExtensionRight,UEWristExtensionLeft,UEHandGripStrengthRight,UEHandGripStrengthLeft,UEHandFingerAbductorsRight,UEHandFingerAbductorsLeft";
                query = query + ") values (";

                query = query + "'" + txtIntactExcept.Text + "','" + LEdtr.Checked + "','" + RTricepstxt.Text + "','" + LTricepstxt.Text + "','" + RBicepstxt.Text + "','" + LBicepstxt.Text + "','" + RBrachioradialis.Text + "','" + LBrachioradialis.Text + "','" + UExchk.Checked + "','" + LKnee.Text + "','" + RKnee.Text + "','" + LAnkle.Text + "','" + RAnkle.Text + "','" + txtSensory.Text.Replace("'", "''") + "','" + chkPinPrick.Checked + "','" + chkLighttouch.Checked + "',";
                query = query + "'" + LESen_Click.Checked + "','" + TextBox4.Text + "','" + txtDMTL3.Text + "','" + TextBox6.Text + "','" + TextBox5.Text + "','" + TextBox8.Text + "','" + TextBox7.Text + "','" + TextBox10.Text + "','" + TextBox21.Text + "','" + TextBox24.Text + "','" + TextBox25.Text + "','" + UESen_Click.Checked + "','" + TextBox9.Text + "','" + txtUEC5Right.Text + "','" + TextBox11.Text + "','" + TextBox12.Text + "','" + TextBox13.Text + "','" + TextBox14.Text + "','" + TextBox15.Text + "','" + TextBox16.Text + "','" + TextBox18.Text + "','" + TextBox17.Text + "','" + TextBox20.Text + "','" + TextBox19.Text + "',";
                query = query + "'" + LEmmst.Checked + "','" + TextBox23.Text + "','" + TextBox22.Text + "','" + TextBox41.Text + "','" + TextBox40.Text + "','" + TextBox27.Text + "','" + TextBox26.Text + "','" + TextBox43.Text + "','" + TextBox42.Text + "','" + TextBox29.Text + "','" + TextBox28.Text + "','" + TextBox45.Text + "','" + TextBox44.Text + "','" + TextBox47.Text + "','" + TextBox46.Text + "',";
                query = query + "'" + UEmmst.Checked + "','" + TextBox31.Text + "','" + TextBox30.Text + "','" + TextBox49.Text + "','" + TextBox48.Text + "','" + TextBox33.Text + "','" + TextBox32.Text + "','" + TextBox51.Text + "','" + TextBox50.Text + "','" + TextBox53.Text + "','" + TextBox52.Text + "','" + TextBox55.Text + "','" + TextBox54.Text + "','" + TextBox37.Text + "','" + TextBox36.Text + "','" + TextBox57.Text + "','" + TextBox56.Text + "','" + TextBox39.Text + "','" + TextBox38.Text + "','" + TextBox59.Text + "','" + TextBox58.Text + "')";
            }
            else
            {
                query = "update tblPatientIEDetailPage2 set ";

                query = query + "intactexcept='" + txtIntactExcept.Text + "',LEdtr = '" + LEdtr.Checked + "',DTRtricepsRight = '" + RTricepstxt.Text + "',DTRtricepsLeft ='" + LTricepstxt.Text + "',DTRBicepsRight ='" + RBicepstxt.Text + "',DTRBicepsLeft = '" + LBicepstxt.Text + "',DTRBrachioRight ='" + RBrachioradialis.Text + "',DTRBrachioLeft = '" + LBrachioradialis.Text + "' ,UEdtr = '" + UExchk.Checked + "',DTRKneeLeft = '" + LKnee.Text + "',DTRKneeRight = '" + RKnee.Text + "',DTRAnkleLeft = '" + LAnkle.Text + "' ,DTRAnkleRight  = '" + RAnkle.Text + "',Sensory = '" + txtSensory.Text.Replace("'", "''") + "',PinPrick = '" + chkPinPrick.Checked + "',Lighttouch = '" + chkLighttouch.Checked + "',";
                query = query + "LEsen = '" + LESen_Click.Checked + "',LEL3Right = '" + TextBox4.Text + "',LEL3Left = '" + txtDMTL3.Text + "',LEL4Right = '" + TextBox6.Text + "',LEL4Left = '" + TextBox5.Text + "',LEL5Right = '" + TextBox8.Text + "',LEL5Left = '" + TextBox7.Text + "',LES1Left = '" + TextBox10.Text + "',LES1Right = '" + TextBox21.Text + "',LELumberParaspinalsLeft = '" + TextBox24.Text + "',LELumberParaspinalsRight = '" + TextBox25.Text + "',UEsen ='" + UESen_Click.Checked + "',UEC5Left = '" + TextBox9.Text + "',UEC5Right = '" + txtUEC5Right.Text + "',UEC6Left = '" + TextBox11.Text + "',UEC6Right = '" + TextBox12.Text + "',UEC7Left = '" + TextBox13.Text + "',UEC7Right = '" + TextBox14.Text + "',UEC8Left = '" + TextBox15.Text + "',UEC8Right = '" + TextBox16.Text + "',UET1Right = '" + TextBox18.Text + "',UET1Left = '" + TextBox17.Text + "',UECervicalParaspinalsRight = '" + TextBox20.Text + "',UECervicalParaspinalsLeft = '" + TextBox19.Text + "',";
                query = query + "LEmmst = '" + LEmmst.Checked + "',LEHipFlexionRight = '" + TextBox23.Text + "',LEHipFlexionLeft = '" + TextBox22.Text + "',LEHipAbductionRight = '" + TextBox41.Text + "',LEHipAbductionLeft  = '" + TextBox40.Text + "',LEKneeExtensionRight = '" + TextBox27.Text + "',LEKneeExtensionLeft = '" + TextBox26.Text + "',LEKneeFlexionRight = '" + TextBox43.Text + "',LEKneeFlexionLeft = '" + TextBox42.Text + "',LEAnkleDorsiRight = '" + TextBox29.Text + "',LEAnkleDorsiLeft = '" + TextBox28.Text + "',LEAnklePlantarRight = '" + TextBox45.Text + "',LEAnklePlantarLeft = '" + TextBox44.Text + "',LEAnkleExtensorRight = '" + TextBox47.Text + "',LEAnkleExtensorLeft = '" + TextBox46.Text + "',";
                query = query + "UEmmst = '" + UEmmst.Checked + "',UEShoulderAbductionRight = '" + TextBox31.Text + "',UEShoulderAbductionLeft = '" + TextBox30.Text + "',UEShoulderFlexionRight = '" + TextBox49.Text + "',UEShoulderFlexionLeft = '" + TextBox48.Text + "',UEElbowExtensionRight = '" + TextBox33.Text + "',UEElbowExtensionLeft = '" + TextBox32.Text + "',UEElbowFlexionRight = '" + TextBox51.Text + "',UEElbowFlexionLeft = '" + TextBox50.Text + "',UEElbowSupinationRight = '" + TextBox53.Text + "',UEElbowSupinationLeft = '" + TextBox52.Text + "',UEElbowPronationRight = '" + TextBox55.Text + "',UEElbowPronationLeft = '" + TextBox54.Text + "',UEWristFlexionRight = '" + TextBox37.Text + "',UEWristFlexionLeft = '" + TextBox36.Text + "',UEWristExtensionRight = '" + TextBox57.Text + "',UEWristExtensionLeft = '" + TextBox56.Text + "',UEHandGripStrengthRight = '" + TextBox39.Text + "',UEHandGripStrengthLeft = '" + TextBox38.Text + "',UEHandFingerAbductorsRight = '" + TextBox59.Text + "',UEHandFingerAbductorsLeft = '" + TextBox58.Text + "'";
                query = query + " Where PatientIE_ID=" + Session["PatientIE_ID"].ToString() + "";
            }
            ds.Dispose();

            int val = db.executeQuery(query);

            query = "select top 1 * from tblPage3HTMLContent where PatientIE_ID=" + Session["PatientIE_ID"].ToString();
            ds    = db.selectData(query);
            if (ds.Tables[0].Rows.Count == 0)
            {
                query = "insert into tblPage3HTMLContent(PatientIE_ID,HTMLContent,topSectionHTML)values(@PatientIE_ID,@HTMLContent,@topSectionHTML)";
            }
            else
            {
                query = "update tblPage3HTMLContent set HTMLContent=@HTMLContent,topSectionHTML=@topSectionHTML where PatientIE_ID=@PatientIE_ID";
            }

            using (SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString))
                using (SqlCommand command = new SqlCommand(query, connection))
                {
                    command.Parameters.AddWithValue("@PatientIE_ID", Session["PatientIE_ID"].ToString());
                    command.Parameters.AddWithValue("@HTMLContent", hdHTMLContent.Value);
                    command.Parameters.AddWithValue("@topSectionHTML", hdtopHTMLContent.Value);


                    connection.Open();
                    var results = command.ExecuteNonQuery();
                    connection.Close();
                }


            if (val > 0)
            {
                try
                {
                    long   _ieID     = Convert.ToInt64(Session["PatientIE_ID"].ToString());
                    string _ieMode   = "";
                    string sProvider = ConfigurationManager.ConnectionStrings["connString_V3"].ConnectionString;
                    string SqlStr    = "";
                    oSQLConn.ConnectionString = sProvider;
                    oSQLConn.Open();
                    SqlStr = "Select * from tblPatientIEDetailPage3 WHERE PatientIE_ID = " + _ieID;
                    SqlDataAdapter    sqlAdapt      = new SqlDataAdapter(SqlStr, oSQLConn);
                    SqlCommandBuilder sqlCmdBuilder = new SqlCommandBuilder(sqlAdapt);
                    DataTable         sqlTbl        = new DataTable();
                    sqlAdapt.Fill(sqlTbl);
                    DataRow TblRow;

                    if (sqlTbl.Rows.Count == 0)
                    {
                        _ieMode = "New";
                    }
                    else if (sqlTbl.Rows.Count > 0)
                    {
                        _ieMode = "Update";
                    }

                    if (_ieMode == "New")
                    {
                        TblRow = sqlTbl.NewRow();
                    }
                    else if (_ieMode == "Update")
                    {
                        TblRow = sqlTbl.Rows[0];
                        TblRow.AcceptChanges();
                    }
                    else
                    {
                        TblRow = null;
                    }

                    if (_ieMode == "Update" || _ieMode == "New")
                    {
                        TblRow["PatientIE_ID"]       = _ieID;
                        TblRow["GAIT"]               = cboGAIT.Text.ToString();
                        TblRow["Ambulates"]          = cboAmbulates.Text.ToString();
                        TblRow["Footslap"]           = chkFootslap.Checked;
                        TblRow["Kneehyperextension"] = chkKneehyperextension.Checked;
                        TblRow["Unabletohealwalk"]   = chkUnabletohealwalk.Checked;
                        TblRow["Unabletotoewalk"]    = chkUnabletotoewalk.Checked;
                        TblRow["Other"]              = txtOther.Text.ToString();

                        if (_ieMode == "New")
                        {
                            TblRow["CreatedBy"]   = "Admin";
                            TblRow["CreatedDate"] = DateTime.Now;
                            sqlTbl.Rows.Add(TblRow);
                        }
                        sqlAdapt.Update(sqlTbl);
                    }
                    if (TblRow != null)
                    {
                        TblRow.Table.Dispose();
                    }
                    sqlTbl.Dispose();
                    sqlCmdBuilder.Dispose();
                    sqlAdapt.Dispose();
                    oSQLConn.Close();
                }
                catch (Exception ex)
                {
                    oSQLConn.Close();
                }
            }


            ScriptManager.RegisterClientScriptBlock(Page, Page.GetType(), Guid.NewGuid().ToString(), "openPopup('mymodelmessage')", true);
            Logger.Info(Session["UserId"].ToString() + "--" + Session["uname"].ToString().Trim() + "-- Create IE - Page4 " + Session["PatientIE_ID"].ToString() + "--" + DateTime.Now);
            if (pageHDN.Value != null && pageHDN.Value != "")
            {
                Response.Redirect(pageHDN.Value.ToString());
            }
            else
            {
                Response.Redirect("Page5.aspx");
            }
        }
        catch (Exception ex)
        {
        }
    }
示例#30
0
    private void bindData()
    {
        DBHelperClass db    = new DBHelperClass();
        string        query = "";

        query = "select top 1 * from tblPatientIEDetailPage2 where PatientIE_ID=" + Session["PatientIE_ID"].ToString();
        DataSet ds = db.selectData(query);

        if (ds.Tables[0].Rows.Count > 0)
        {
            //chk_seizures.Checked = ds.Tables[0].Rows[0]["Seizures"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Seizures"].ToString()) : false;
            //chk_chest_pain.Checked = ds.Tables[0].Rows[0]["ChestPain"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["ChestPain"].ToString()) : false;
            //chk_shortness_of_breath.Checked = ds.Tables[0].Rows[0]["ShortnessOfBreath"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["ShortnessOfBreath"].ToString()) : false;
            //chk_jaw_pain.Checked = ds.Tables[0].Rows[0]["Jawpain"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Jawpain"].ToString()) : false;
            //chk_abdominal_pain.Checked = ds.Tables[0].Rows[0]["AbdominalPain"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["AbdominalPain"].ToString()) : false;
            //chk_fever.Checked = ds.Tables[0].Rows[0]["Fevers"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Fevers"].ToString()) : false;
            //chk_diarrhea.Checked = ds.Tables[0].Rows[0]["Diarrhea"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Diarrhea"].ToString()) : false;
            //chk_bowel_bladder.Checked = ds.Tables[0].Rows[0]["Bowel"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Bowel"].ToString()) : false;
            //chk_blurred.Checked = ds.Tables[0].Rows[0]["DoubleVision"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["DoubleVision"].ToString()) : false;
            //chk_recent_wt.Checked = ds.Tables[0].Rows[0]["RecentWeightloss"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["RecentWeightloss"].ToString()) : false;
            //chk_episodic_ligth.Checked = ds.Tables[0].Rows[0]["Episodic"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Episodic"].ToString()) : false;
            //chk_rashes.Checked = ds.Tables[0].Rows[0]["Rashes"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Rashes"].ToString()) : false;
            //chk_hearing_loss.Checked = ds.Tables[0].Rows[0]["HearingLoss"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["HearingLoss"].ToString()) : false;
            //chk_sleep_disturbance.Checked = ds.Tables[0].Rows[0]["NightSweats"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["NightSweats"].ToString()) : false;
            //chk_depression.Checked = ds.Tables[0].Rows[0]["Depression"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Depression"].ToString()) : false;

            //chk_bloodinurine.Checked = ds.Tables[0].Rows[0]["dloodinurine"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["dloodinurine"].ToString()) : false;

            LTricepstxt.Text      = Convert.ToString(ds.Tables[0].Rows[0]["DTRtricepsLeft"]);
            RTricepstxt.Text      = Convert.ToString(ds.Tables[0].Rows[0]["DTRtricepsRight"]);
            LBicepstxt.Text       = Convert.ToString(ds.Tables[0].Rows[0]["DTRBicepsLeft"]);
            RBicepstxt.Text       = Convert.ToString(ds.Tables[0].Rows[0]["DTRBicepsRight"]);
            RBrachioradialis.Text = Convert.ToString(ds.Tables[0].Rows[0]["DTRBrachioRight"]);
            LBrachioradialis.Text = Convert.ToString(ds.Tables[0].Rows[0]["DTRBrachioLeft"]);
            LKnee.Text            = Convert.ToString(ds.Tables[0].Rows[0]["DTRKneeLeft"]);
            RKnee.Text            = Convert.ToString(ds.Tables[0].Rows[0]["DTRKneeRight"]);
            LAnkle.Text           = Convert.ToString(ds.Tables[0].Rows[0]["DTRAnkleLeft"]);
            RAnkle.Text           = Convert.ToString(ds.Tables[0].Rows[0]["DTRAnkleRight"]);
            UExchk.Checked        = ds.Tables[0].Rows[0]["UEdtr"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["UEdtr"].ToString()) : false;
            chkPinPrick.Checked   = ds.Tables[0].Rows[0]["Pinprick"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Pinprick"].ToString()) : false;
            chkLighttouch.Checked = ds.Tables[0].Rows[0]["Lighttouch"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Lighttouch"].ToString()) : false;
            txtSensory.Text       = Convert.ToString(ds.Tables[0].Rows[0]["Sensory"]);
            LESen_Click.Checked   = ds.Tables[0].Rows[0]["LEsen"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["LEsen"].ToString()) : false;
            TextBox4.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL3Right"]);
            txtDMTL3.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL3Left"]);
            TextBox6.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL4Right"]);
            TextBox5.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL4Left"]);
            TextBox8.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL5Right"]);
            TextBox7.Text         = Convert.ToString(ds.Tables[0].Rows[0]["LEL5Left"]);
            TextBox10.Text        = Convert.ToString(ds.Tables[0].Rows[0]["LES1Left"]);
            TextBox21.Text        = Convert.ToString(ds.Tables[0].Rows[0]["LES1Right"]);
            TextBox25.Text        = Convert.ToString(ds.Tables[0].Rows[0]["LELumberParaspinalsRight"]);
            TextBox24.Text        = Convert.ToString(ds.Tables[0].Rows[0]["LELumberParaspinalsLeft"]);
            UESen_Click.Checked   = ds.Tables[0].Rows[0]["UEsen"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["UEsen"].ToString()) : false;
            TextBox9.Text         = Convert.ToString(ds.Tables[0].Rows[0]["UEC5Left"]);
            txtUEC5Right.Text     = Convert.ToString(ds.Tables[0].Rows[0]["UEC5Right"]);
            TextBox11.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC6Left"]);
            TextBox12.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC6Right"]);
            TextBox13.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC7Left"]);
            TextBox14.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC7Right"]);
            TextBox15.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC8Left"]);
            TextBox16.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UEC8Right"]);
            TextBox18.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UET1Right"]);
            TextBox17.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UET1Left"]);
            TextBox20.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UECervicalParaspinalsRight"]);
            TextBox19.Text        = Convert.ToString(ds.Tables[0].Rows[0]["UECervicalParaspinalsLeft"]);
            //  cboHoffmanexam.SelectedValue = Convert.ToString(ds.Tables[0].Rows[0]["HoffmanExam"]);
            // chkStocking.Checked = ds.Tables[0].Rows[0]["Stocking"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Stocking"].ToString()) : false;
            //chkGlove.Checked = ds.Tables[0].Rows[0]["Glove"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["Glove"].ToString()) : false;
            LEmmst.Checked       = ds.Tables[0].Rows[0]["LEmmst"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["LEmmst"].ToString()) : false;
            TextBox23.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEHipFlexionRight"]);
            TextBox22.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEHipFlexionLeft"]);
            TextBox41.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEHipAbductionRight"]);
            TextBox40.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEHipAbductionLeft"]);
            TextBox27.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEKneeExtensionRight"]);
            TextBox26.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEKneeExtensionLeft"]);
            TextBox43.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEKneeFlexionRight"]);
            TextBox42.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEKneeFlexionLeft"]);
            TextBox29.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnkleDorsiRight"]);
            TextBox28.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnkleDorsiLeft"]);
            TextBox45.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnklePlantarRight"]);
            TextBox44.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnklePlantarLeft"]);
            TextBox47.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnkleExtensorRight"]);
            TextBox46.Text       = Convert.ToString(ds.Tables[0].Rows[0]["LEAnkleExtensorLeft"]);
            UEmmst.Checked       = ds.Tables[0].Rows[0]["UEmmst"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["UEmmst"].ToString()) : false;
            TextBox31.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEShoulderAbductionRight"]);
            TextBox30.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEShoulderAbductionLeft"]);
            TextBox49.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEShoulderFlexionRight"]);
            TextBox48.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEShoulderFlexionLeft"]);
            TextBox33.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowExtensionRight"]);
            TextBox32.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowExtensionLeft"]);
            TextBox51.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowFlexionRight"]);
            TextBox50.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowFlexionLeft"]);
            TextBox53.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowSupinationRight"]);
            TextBox52.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowSupinationLeft"]);
            TextBox55.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowPronationRight"]);
            TextBox54.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEElbowPronationLeft"]);
            TextBox37.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEWristFlexionRight"]);
            TextBox36.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEWristFlexionLeft"]);
            TextBox57.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEWristExtensionRight"]);
            TextBox56.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEWristExtensionLeft"]);
            TextBox39.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEHandGripStrengthRight"]);
            TextBox38.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEHandGripStrengthLeft"]);
            TextBox59.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEHandFingerAbductorsRight"]);
            TextBox58.Text       = Convert.ToString(ds.Tables[0].Rows[0]["UEHandFingerAbductorsLeft"]);
            txtIntactExcept.Text = Convert.ToString(ds.Tables[0].Rows[0]["intactexcept"]);
            LEdtr.Checked        = ds.Tables[0].Rows[0]["LEdtr"] != DBNull.Value ? Convert.ToBoolean(ds.Tables[0].Rows[0]["LEdtr"].ToString()) : false;
        }
        else
        {
            PopulateUIDefaults();
        }

        query = "select * from tblPage3HTMLContent where  PatientIE_ID=" + Session["PatientIE_ID"].ToString();
        ds    = db.selectData(query);

        if (ds.Tables[0].Rows.Count > 0)
        {
            divHtml.InnerHtml    = ds.Tables[0].Rows[0]["HTMLContent"].ToString();
            divtopHtml.InnerHtml = ds.Tables[0].Rows[0]["topSectionHTML"].ToString();
        }
        else
        {
            bindHtml();
        }

        query = "Select * from tblPatientIEDetailPage3 WHERE PatientIE_ID = " + Session["PatientIE_ID"].ToString();
        ds    = db.selectData(query);


        if (ds.Tables[0].Rows.Count > 0)
        {
            cboGAIT.Text                  = ds.Tables[0].Rows[0]["GAIT"].ToString().Trim();
            cboAmbulates.Text             = ds.Tables[0].Rows[0]["Ambulates"].ToString().Trim();
            chkFootslap.Checked           = CommonConvert.ToBoolean(ds.Tables[0].Rows[0]["Footslap"].ToString());
            chkKneehyperextension.Checked = CommonConvert.ToBoolean(ds.Tables[0].Rows[0]["Kneehyperextension"].ToString());
            chkUnabletohealwalk.Checked   = CommonConvert.ToBoolean(ds.Tables[0].Rows[0]["Unabletohealwalk"].ToString());
            chkUnabletotoewalk.Checked    = CommonConvert.ToBoolean(ds.Tables[0].Rows[0]["Unabletotoewalk"].ToString());
            txtOther.Text                 = ds.Tables[0].Rows[0]["Other"].ToString().Trim();
        }
    }