Example #1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     try
     {
         this.CargarComboBox();
         this.CargarComboEstado();
         _dataCart = ObtenerDatosDinamicos();
         EM_Clientes Cliente = new EM_Clientes();
         Cliente.Conexion  = Comun.Conexion;
         Cliente.IdCliente = HttpContext.Current.Profile.UserName;
         bool esAnonimo = !Request.IsAuthenticated;
         if (esAnonimo == true)
         {
             this.IniciarDatos();
         }
         else
         {
             EM_ClienteNegocio CN = new EM_ClienteNegocio();
             CN.ObtenerCliente(Cliente);
             this.CargarDatos(Cliente);
         }
         if (!_dataCart.Completado)
         {
             Response.Redirect("/ErrorPage", true);
         }
     }
     catch (Exception)
     {
         Response.Redirect("/ErrorPage", true);
     }
 }