using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using QuintoCaminoV2.Data_objects;

namespace QuintoCaminoV2.Charlas
{
    public partial class Charlas : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            getCharlas();
        }

        public void getCharlas()
        {

            DataLayer oDataLayer = new DataLayer();
            Data_objects.Charlas oCharlas = new Data_objects.Charlas();
            DataCharlas.DataSource = oDataLayer.get_Charlas(oCharlas);
            DataCharlas.DataBind();


        }

        protected void DataCharlas_ItemCommand(object source, DataListCommandEventArgs e)
        {
            string oValor;
            //oValor = ((DataListItem)DataCharlas.SelectedItem.;

        }

        protected void LinkButton1_Click(object sender, EventArgs e)
        {
            string oValor;
            LinkButton obj = (LinkButton)sender;
            oValor = obj.CommandArgument;

            //DetalleCharlas oCharla = new DetalleCharlas(Convert.ToInt16(oValor));
            Response.Redirect("DetalleCharlas.aspx?IdCharla=" + oValor);

        }
    }
}