コード例 #1
0
    protected void ButtonShow_Click(object sender, EventArgs e)
    {

        DateTime start = new DateTime();
        DateTime end = new DateTime();

        if (DateTime.TryParse(TxtFromDate.Value, out start)
            && DateTime.TryParse(TxtToDate.Value, out end))
        {
            int id = Convert.ToInt32(Session["PatientId"]);

            DataTable table = GetOpenItems(id, start, end);
            if (table.Rows.Count > 0)
            {
                btnSubmit.Enabled = CanSubmit;
                GridViewTran.DataSource = table;
                GridViewTran.DataBind();
            }
            else
            {
                btnSubmit.Enabled = false;
                GridViewTran.DataSource = null;
                GridViewTran.DataBind();
            }
        }
        else
        {
            // bad dates
            int foo = 0; // for setting breakpoint in dev
        }
    }
コード例 #2
0
        private void ShowDetails(int billid)
        {
            IPatientHome PatientManager;

            PatientManager =
                (IPatientHome)
                ObjectFactory.CreateInstance("BusinessProcess.Clinical.BPatientHome, BusinessProcess.Clinical");
            //DataSe dataTable = PatientManager.GetPatientDebitNoteDetails(billid);
            //GridViewTran.DataSource = dataTable;

            GridViewTran.DataBind();
        }
コード例 #3
0
        private void LoadSummaryGridView()
        {
            IPatientHome PatientManager;

            PatientManager =
                (IPatientHome)ObjectFactory.CreateInstance("BusinessProcess.Clinical.BPatientHome, BusinessProcess.Clinical");
            DataTable dataTable = PatientManager.GetPatientDebitNoteSummary(Convert.ToInt32(Session["PatientId"]));

            GridViewSummary.DataSource = dataTable;
            AddFormattedDateColumn(dataTable);
            GridViewSummary.DataBind();
            GridViewTran.DataSource = null;
            GridViewTran.DataBind();
        }