public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { reporteVentas rpt = new reporteVentas(); rpt.Site = this.Site; return(rpt); }
private void btnReporte_Click(object sender, EventArgs e) { reporteVentas rv = new reporteVentas(); if (this.tipo == 1) { if (validacion.validarNombres(this.txtReporte.Text) && !this.txtReporte.Text.Equals(string.Empty)) { rv.SetDataSource(cn.reporte.reporte.reporteVentasProducto(this.txtReporte.Text)); } } else if (this.tipo == 2) { if (validacion.validarNombreProducto(this.txtReporte.Text) && !this.txtReporte.Text.Equals(string.Empty)) { rv.SetDataSource(cn.reporte.reporte.reporteVentasNombre(this.txtReporte.Text)); } } else if (this.tipo == 3) { rv.SetDataSource(cn.reporte.reporte.reporteVentasPeriodo(dtpInicio.Value, dtpFin.Value)); } this.crystalReportViewer1.ReportSource = rv; }
private void btnReporte_Click(object sender, EventArgs e) { reporteVentas rv = new reporteVentas(); if (this.tipo == 1) { if (validacion.validarNombres(this.txtReporte.Text) && !this.txtReporte.Text.Equals(string.Empty)) { rv.SetDataSource(cn.reporte.reporte.reporteVentasProducto(this.txtReporte.Text)); } } else if (this.tipo == 2) { if (validacion.validarNombreProducto(this.txtReporte.Text) && !this.txtReporte.Text.Equals(string.Empty)) { rv.SetDataSource(cn.reporte.reporte.reporteVentasNombre(this.txtReporte.Text)); } } else if (this.tipo == 3) { rv.SetDataSource(cn.reporte.reporte.reporteVentasPeriodo(dtpInicio.Value,dtpFin.Value)); } this.crystalReportViewer1.ReportSource = rv; }
public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { reporteVentas rpt = new reporteVentas(); rpt.Site = this.Site; return rpt; }