Ejemplo n.º 1
0
 /// <summary>
 /// Bind observation categories
 /// </summary>
 public void VET_Get_ObservationCategories()
 {
     try
     {
         BLL_VET_Index objBLLIndx = new BLL_VET_Index();
         string        Mode       = "Edit";
         DataTable     dt         = objBLLIndx.VET_Get_ObservationCategories(Mode);
         DDLCategories.DataSource     = dt;
         DDLCategories.DataTextField  = "OBSCategory_Name";
         DDLCategories.DataValueField = "OBSCategory_ID";
         DDLCategories.DataBind();
     }
     catch (Exception ex)
     {
         UDFLib.WriteExceptionLog(ex);
         string js = "alert('" + UDFLib.GetException("SystemError/ GeneralMessage") + "');";
         ScriptManager.RegisterStartupScript(this, this.GetType(), "error", js, true);
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Bind observation categories
 /// </summary>
 public void BindVettingObservationCategories()
 {
     try
     {
         BLL_VET_Index oVT = new BLL_VET_Index();
         DataTable     dt  = oVT.VET_Get_ObservationCategories("Edit");
         lstObservationCategory.DataSource     = dt;
         lstObservationCategory.DataTextField  = "OBSCategory_Name";
         lstObservationCategory.DataValueField = "OBSCategory_ID";
         lstObservationCategory.DataBind();
         lstObservationCategory.Items.Insert(0, new ListItem("-SELECT ALL-", "0"));
     }
     catch (Exception ex)
     {
         UDFLib.WriteExceptionLog(ex);
         string js = "alert('" + UDFLib.GetException("SystemError/ GeneralMessage") + "');";
         ScriptManager.RegisterStartupScript(this, this.GetType(), "error", js, true);
     }
 }
 /// <summary>
 /// Method is used to bind observation categories
 /// </summary>
 public void VET_Get_ObservationCategories()
 {
     try
     {
         BLL_VET_Index objBLLIndx = new BLL_VET_Index();
         DataTable     dtCategory = objBLLIndx.VET_Get_ObservationCategories(ViewState["Mode"].ToString());
         ddlCategory.Items.Clear();
         ddlCategory.DataSource     = dtCategory;
         ddlCategory.DataTextField  = "OBSCategory_Name";
         ddlCategory.DataValueField = "OBSCategory_ID";
         ddlCategory.DataBind();
         ListItem li = new ListItem("-Select-", "0");
         ddlCategory.Items.Insert(0, li);
     }
     catch (Exception ex)
     {
         UDFLib.WriteExceptionLog(ex);
         string js = "alert('" + UDFLib.GetException("SystemError/ GeneralMessage") + "');";
         ScriptManager.RegisterStartupScript(this, this.GetType(), "error", js, true);
     }
 }