protected Evento PreencherObjeto()
        {
            Evento    objEvento = new Evento();
            ComandoBO boComando = new ComandoBO();

            objEvento.ObjAgenda.Hora    = Convertt.ToTimeSpan(txtHora.Text);
            objEvento.ObjAgenda.Domingo = chDom.Checked;
            objEvento.ObjAgenda.Segunda = chSeg.Checked;
            objEvento.ObjAgenda.Terca   = chTer.Checked;
            objEvento.ObjAgenda.Quarta  = chQua.Checked;
            objEvento.ObjAgenda.Quinta  = chQui.Checked;
            objEvento.ObjAgenda.Sexta   = chSex.Checked;
            objEvento.ObjAgenda.Sabado  = chSab.Checked;
            if (txtRange.Text != "")
            {
                objEvento.Potencia = Convertt.ToString(txtRange.Text);
            }
            if (hfIdEvento.Value != "")
            {
                objEvento.Id = Convert.ToInt32(hfIdEvento.Value);
            }
            if (hfIdAgenda.Value != "")
            {
                objEvento.ObjAgenda.Id = Convert.ToInt32(hfIdAgenda.Value);
            }
            if (hfIdDispositivo.Value != "")
            {
                objEvento.ObjDispositvo.Id = Convert.ToInt32(hfIdDispositivo.Value);
            }
            for (int i = 0; i < objsRadioButton.Count; i++)
            {
                if (objsRadioButton[i].Checked == true)
                {
                    objEvento.ObjComando = boComando.BuscarComandoIdBotao(objsRadioButton[i].ID);
                }
            }

            return(objEvento);
        }