Ejemplo n.º 1
0
        private Boolean ExisteTipoCambio(DateTime vFecha)
        {
            DateTime   Fcha;
            Boolean    Valor = false;
            CLS_Gastos Clase = new CLS_Gastos();

            Clase.Fecha_Gasto = vFecha.Year.ToString() + DosCero(vFecha.Month.ToString()) + DosCero(vFecha.Day.ToString());
            Clase.MtdSeleccionarTCxFecha();
            if (Clase.Exito)
            {
                if (Clase.Datos.Rows.Count > 0)
                {
                    vTipoCambio = Clase.Datos.Rows[0]["Tipo_Cambio"].ToString();
                    Valor       = true;
                }
                else
                {
                    vTipoCambio = "0";
                }
            }
            return(Valor);
        }
Ejemplo n.º 2
0
        private void CargarTC()
        {
            DateTime Fcha;

            CLS_Gastos Clase = new CLS_Gastos();

            Fcha = Convert.ToDateTime(dateFecha.EditValue);

            Clase.Fecha_Gasto = Fcha.Year.ToString() + DosCero(Fcha.Month.ToString()) + DosCero(Fcha.Day.ToString());
            Clase.MtdSeleccionarTCxFecha();
            if (Clase.Exito)
            {
                if (Clase.Datos.Rows.Count > 0)
                {
                    textTC.Text = Clase.Datos.Rows[0]["Tipo_Cambio"].ToString();
                }
                else
                {
                    textTC.Text = "0";
                }
            }
        }