tenes agregada la rutina como controladora del evento?
Mes.SelectedIndexChanged += Mes_SelectedIndexChanged

Signature
Saludos
Marcos Mellibovsky
MCAD - MCSD - MCSE - MCDBA
Cordoba - Argentina
Hola
Estoy haciendo un usercontrol que tiene un dropdownlist (id=Mes) y no me ejecuta el evento Mes_SelectedIndexChanged(object sender, EventArgs e)...
AutoEventWireUp es TRUE y tambien el autopostback...
alguien sabe que puede estar pasando?
aqui van los codigos...
<%@ Control Language="c#" AutoEventWireup="true" Codebehind="FechaPicker.ascx.cs" Inherits="Voluntarios.controls.FechaPicker" TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
<asp:DropDownList id="Dia" runat="server"></asp:DropDownList>
<asp:DropDownList id="Mes" AutoPostBack=True runat="server"></asp:DropDownList>
<asp:DropDownList id="Ano" AutoPostBack=True runat="server"></asp:DropDownList>
============================================================== void Ano_SelectedIndexChanged(object sender, System.EventArgs e)
{
DateTime xFecha=new DateTime(Convert.ToInt32(Ano.SelectedItem.Value),MyDate.Month,MyDate.Day);
MyDate=xFecha;
}
private void Mes_SelectedIndexChanged(object sender, System.EventArgs e)
{
DateTime xFecha=new DateTime(MyDate.Year,Convert.ToInt32(Mes.SelectedItem.Value),MyDate.Day);
MyDate=xFecha;
}
Jose Fernandez - 31 May 2005 16:21 GMT
Si, lo tengo....
acabo de hacer una paginita tonta, con un usercontrol embedded y en el
usercontrol un dropdown con un textbox y el evento selectedindex y me
funciona....
ahora si que no entiendo nada.
AYUDA POR FAVORRRRRR
private void InitializeComponent()
{
this.Mes.SelectedIndexChanged += new
System.EventHandler(this.Mes_SelectedIndexChanged);
this.Ano.SelectedIndexChanged += new
System.EventHandler(this.Ano_SelectedIndexChanged);
this.Load += new System.EventHandler(this.Page_Load);
}
tenes agregada la rutina como controladora del evento?
Mes.SelectedIndexChanged += Mes_SelectedIndexChanged

Signature
Saludos
Marcos Mellibovsky
MCAD - MCSD - MCSE - MCDBA
Cordoba - Argentina
"Jose Fernandez" <ppcuban@hotmail.com> escribió en el mensaje
news:O%236VhzUZFHA.1088@TK2MSFTNGP14.phx.gbl...
Hola
Estoy haciendo un usercontrol que tiene un dropdownlist (id=Mes) y no me
ejecuta el evento Mes_SelectedIndexChanged(object sender, EventArgs e)...
AutoEventWireUp es TRUE y tambien el autopostback...
alguien sabe que puede estar pasando?
aqui van los codigos...
<%@ Control Language="c#" AutoEventWireup="true"
Codebehind="FechaPicker.ascx.cs" Inherits="Voluntarios.controls.FechaPicker"
TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
<asp:DropDownList id="Dia" runat="server"></asp:DropDownList>
<asp:DropDownList id="Mes" AutoPostBack=True
runat="server"></asp:DropDownList>
<asp:DropDownList id="Ano" AutoPostBack=True
runat="server"></asp:DropDownList>
===============================================================
void Ano_SelectedIndexChanged(object sender, System.EventArgs e)
{
DateTime xFecha=new
DateTime(Convert.ToInt32(Ano.SelectedItem.Value),MyDate.Month,MyDate.Day);
MyDate=xFecha;
}
private void Mes_SelectedIndexChanged(object sender, System.EventArgs e)
{
DateTime xFecha=new
DateTime(MyDate.Year,Convert.ToInt32(Mes.SelectedItem.Value),MyDate.Day);
MyDate=xFecha;
}
Jose Fernandez - 31 May 2005 16:52 GMT
Realmente estoy desesperado. necesito resolver este problema pues tengo solo
esta semana para entregar este trabajo.
los que quieran el codigo fuente completo de estas paginas, escribanme a mi
correo y se los mando.
aprecio muchisimo cualquier ayuda que puedan darme.
Jose ppcuban@hotmail.com
> Si, lo tengo....
>
[quoted text clipped - 16 lines]
>
> Mes.SelectedIndexChanged += Mes_SelectedIndexChanged
Jose Fernandez - 31 May 2005 18:31 GMT
YA
la solucion esta aqui....
El problema era que en esa misma pagina estaba otro usercontrol que tenia un
codigo html y dentro habia un form (del antiguo ASP) y por lo tanto no
permitia hacer postback a la pagina. Por eso era que yo usaba el mismo
usercontrol en otras paginas y me pinchaba bien sin problemas.....
Les agradezco de todos modos la atencion.
un abrazo
> Realmente estoy desesperado. necesito resolver este problema pues tengo
> solo esta semana para entregar este trabajo.
[quoted text clipped - 23 lines]
>>
>> Mes.SelectedIndexChanged += Mes_SelectedIndexChanged