private void Load_BilgeAlarmMonthlyTestingReport_Details(int Main_Report_ID, int Vessel_ID) { try { DataSet ds = BLL_DANFormO2AlcoholTestLog.Get_DNA_Alcohol_Test_Log(Main_Report_ID, Vessel_ID); GridView_CargoHoldBilgeAlarm.DataSource = ds.Tables[0]; GridView_CargoHoldBilgeAlarm.DataBind(); if (ds.Tables[1].Rows.Count > 0) { lblReportDate.Text = ds.Tables[1].Rows[0]["ReportDate"].ToString(); lblVesselName.Text = ds.Tables[1].Rows[0]["Vessel_Name"].ToString(); } } catch { } }
private void Load_BilgeAlarmMonthlyTestingReport_Details(int Main_Report_ID, int Vessel_ID) { try { DataSet dsmain = BilgeAlarmMonthlyTestingReport.BLL_FRM_BilgeAlarmMonthlyTestingReport.Get_BilgeAlarmMonthlyTestingReport_Main(Main_Report_ID, Vessel_ID); if (dsmain.Tables[0].Rows.Count > 0) { //txtOtherAlarmSensors.Text = dsmain.Tables[0].Rows[0]["Cargo_hold_blidge_Alarm_sensors"].ToString(); //txtEngineAlarmSensors.Text = dsmain.Tables[0].Rows[0]["Engine_room_blidge_Alarm_sensors"].ToString(); //txtCargoAlarmSensors.Text = dsmain.Tables[0].Rows[0]["Other_blidge_Alarm_sensors"].ToString(); //txtNote.Text = dsmain.Tables[0].Rows[0]["Bilge_Alarm_Note"].ToString(); lblReportDate.Text = dsmain.Tables[0].Rows[0]["ReportDate"].ToString(); lblVesselName.Text = dsmain.Tables[0].Rows[0]["Vessel_Name"].ToString(); //txtMonth.Text = dsmain.Tables[0].Rows[0]["Report_Month"].ToString(); //txtYear.Text = dsmain.Tables[0].Rows[0]["Report_Year"].ToString(); //gEditReport.Visibility = Visibility.Visible; //dtpReportDate.Visibility = Visibility.Hidden; //txtReportDate.Visibility = Visibility.Hidden; } DataSet ds = BilgeAlarmMonthlyTestingReport.BLL_FRM_BilgeAlarmMonthlyTestingReport.Get_BilgeAlarmMonthlyTestingReport_Details(Main_Report_ID, Vessel_ID); //this.DataContext = ds.Tables[0]; GridView_CargoHoldBilgeAlarm.DataSource = ds.Tables[0]; GridView_CargoHoldBilgeAlarm.DataBind(); GridView_ERBilgeAlarm.DataSource = ds.Tables[1]; GridView_ERBilgeAlarm.DataBind(); GridView_OtherBilgeAlarm.DataSource = ds.Tables[2]; GridView_OtherBilgeAlarm.DataBind(); } catch { } }