Beispiel #1
0
    public void cargarTabla()
    {
        string sql = "";

        try{
            OracleConnection conn = con.crearConexion();
            OracleCommand    cmd  = null;
            if (conn != null)
            {
                sql = "SELECT OBS_CODIGO, OBS_DESCRIPCION FROM OBSERVACION  WHERE PROP_CODIGO ='" + Metodo.Value + "' and OBS_REALIZADA!='DIRECTOR'";

                cmd             = new OracleCommand(sql, conn);
                cmd.CommandType = CommandType.Text;
                using (OracleDataReader reader = cmd.ExecuteReader()){
                    DataTable dataTable = new DataTable();
                    dataTable.Load(reader);
                    GVobservacion.DataSource = dataTable;
                    int cantfilas = Convert.ToInt32(dataTable.Rows.Count.ToString());
                }
                GVobservacion.DataBind();
            }
            conn.Close();
        } catch (Exception ex) {
            Linfo.Text = "Error al cargar la lista: " + ex.StackTrace;
        }
    }
    public void ResultadoObservaciones()
    {
        try{
            OracleConnection conn = con.crearConexion();
            OracleCommand    cmd  = null;
            if (conn != null)
            {
                string sql = "SELECT DISTINCT O.OBS_CODIGO, O.OBS_DESCRIPCION, O.OBS_REALIZADA FROM OBSERVACION O, ESTUDIANTE E WHERE E.PROP_CODIGO=O.PROP_CODIGO AND E.USU_USERNAME='******' ORDER BY O.OBS_CODIGO";

                cmd             = new OracleCommand(sql, conn);
                cmd.CommandType = CommandType.Text;
                using (OracleDataReader reader = cmd.ExecuteReader()){
                    DataTable dataTable = new DataTable();
                    dataTable.Load(reader);
                    GVobservacion.DataSource = dataTable;
                    int cantfilas = Convert.ToInt32(dataTable.Rows.Count.ToString());
                    Linfo.Text = "Cantidad de filas encontradas: " + cantfilas;
                }
                GVobservacion.DataBind();
            }
            conn.Close();
        }catch (Exception ex) {
            Linfo.Text = "Error al cargar la lista: " + ex.Message;
        }
    }
Beispiel #3
0
    public void ResultadoObservaciones()
    {
        Linfo.Text = "";
        try{
            OracleConnection conn = con.crearConexion();
            OracleCommand    cmd  = null;
            if (conn != null)
            {
                string sql = "SELECT PFOBS_CODIGO,PFOBS_DESCRIPCION, PFOBS_REALIZADA FROM PF_OBSERVACIONES  WHERE PPRO_CODIGO ='" + Codigop.Value + "'";

                cmd             = new OracleCommand(sql, conn);
                cmd.CommandType = CommandType.Text;
                using (OracleDataReader reader = cmd.ExecuteReader()){
                    DataTable dataTable = new DataTable();
                    dataTable.Load(reader);
                    GVobservacion.DataSource = dataTable;
                    int cantfilas = Convert.ToInt32(dataTable.Rows.Count.ToString());
                }
                GVobservacion.DataBind();
            }
            conn.Close();
        }catch (Exception ex) {
            Linfo.Text = "Error al cargar la lista: " + ex.Message;
        }
    }
 public void cargarTabla()
 {
     try {
         OracleConnection conn = con.crearConexion();
         OracleCommand    cmd  = null;
         if (conn != null)
         {
             string sql = " SELECT PFOBS_CODIGO, PFOBS_DESCRIPCION FROM PF_OBSERVACIONES WHERE PPRO_CODIGO = '" + Metodo.Value + "'";
             cmd             = new OracleCommand(sql, conn);
             cmd.CommandType = CommandType.Text;
             using (OracleDataReader reader = cmd.ExecuteReader()){
                 DataTable dataTable = new DataTable();
                 dataTable.Load(reader);
                 GVobservacion.DataSource = dataTable;
             }
             GVobservacion.DataBind();
         }
         conn.Close();
     } catch (Exception ex) {
         Linfo.Text = "Error al cargar la lista: " + ex.Message;
     }
 }
Beispiel #5
0
    public void cargarTabla()
    {
        string sql = "";

        try {
            OracleConnection conn = con.crearConexion();
            OracleCommand    cmd  = null;
            if (conn != null)
            {
                sql = "SELECT a.AOBS_CODIGO, a.AOBS_DESCRIPCION FROM ANTE_OBSERVACION a, EVALUADOR e WHERE a.APROP_CODIGO ='" + Metodo.Value + "' and a.AOBS_REALIZADA='EVALUADOR' and e.APRO_CODIGO = a.APROP_CODIGO and e.USU_USERNAME = '******'";

                cmd             = new OracleCommand(sql, conn);
                cmd.CommandType = CommandType.Text;
                using (OracleDataReader reader = cmd.ExecuteReader()){
                    DataTable dataTable = new DataTable();
                    dataTable.Load(reader);
                    GVobservacion.DataSource = dataTable;
                }
                GVobservacion.DataBind();
            }
            conn.Close();
        }
        catch (Exception ex) { }
    }