本文整理汇总了C#中Report.Design方法的典型用法代码示例。如果您正苦于以下问题:C# Report.Design方法的具体用法?C# Report.Design怎么用?C# Report.Design使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Report
的用法示例。
在下文中一共展示了Report.Design方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: btnImprimir_Click
private void btnImprimir_Click(object sender, EventArgs e)
{
var oVendedor = (this.cmbVendedor.SelectedItem as Usuario);
var oRep = new Report();
oRep.Load(GlobalClass.ConfiguracionGlobal.pathReportes + "Comisiones.frx");
oRep.RegisterData(this.dgvVentas.ADataTable(), "Ventas");
oRep.RegisterData(this.dgvTotales.ADataTable(), "Totales");
oRep.SetParameterValue("Vendedor", (oVendedor == null ? "" : oVendedor.NombrePersona));
oRep.SetParameterValue("FechaDe", this.dtpDe.Value);
oRep.SetParameterValue("FechaA", this.dtpA.Value);
oRep.SetParameterValue("Fijo", Util.Decimal(this.lblFijo.Text.SoloNumeric()));
oRep.SetParameterValue("Variable", Util.Decimal(this.lblVariable.Text.SoloNumeric()));
oRep.SetParameterValue("Devolucion", Util.Decimal(this.lblDevoluciones.Text.SoloNumeric()));
oRep.SetParameterValue("Total", Util.Decimal(this.lblTotal.Text.SoloNumeric()));
oRep.Design();
}
示例2: dgBonovi_KeyDown
//.........这里部分代码省略.........
podaciZaReport = new DataTable();
if (glPartner.Text != "")
{
veza.ExecuteQuery("select bonovi.bon_kod, partner.PA_NAZIV, bonovi.bon_rednibroj , bonovi.bon_datumizrade , bonovi.bon_iznos, bonovi.bon_datumkoristenja, bonovi.bon_iznosracuna, bonovi.ifab_ID, concat(operater.op_ime,'',operater.op_prezime), bon_ponisten , bonovi.bon_kasa, bonovi.bon_vazido, bonovi.bon_racunnakasi, poslovnica.po_naziv, ifabon.ifab_datum, (select sum(bonovi.bon_iznos) from bonovi where bonovi.bon_datumkoristenja is not null) as iskoristeno from operater, bonovi left outer join partner on partner.PA_ID = bonovi.partner_pa_ID left outer join poslovnica on poslovnica.po_id = bonovi.poslovnica_po_ID left outer join ifabon on ifabon.ifab_ID = bonovi.ifab_ID where operater.op_ID= bonovi.operater_op_ID and partner.PA_ID = " + glPartner.EditValue + " and bonovi.bon_ponisten = 0 and bonovi.bon_datumizrade between '" + prvi + "' and '" + drugi + "'", ref podaciZaReport);
//DataTable artikli = new DataTable();
//artikli = izdani_bonovi.bonovi.CopyToDataTable();
//create dataset
DataSet FDataSet = new DataSet();
podaciZaReport.TableName = "Artikli";
FDataSet.Tables.Add(podaciZaReport);
// create report instance
Report report = new Report();
// load the existing report
System.Reflection.Assembly a = System.Reflection.Assembly.GetEntryAssembly();
string baseDir = System.IO.Path.GetDirectoryName(a.Location);
report.Load(baseDir + "/report/PregledBonova.frx");
report.SetParameterValue("partner", glPartner.Text);
report.SetParameterValue("naslov", "PREGLED IZDANIH BONOVA ZA:");
report.SetParameterValue("iskoristeno", podaciZaReport.Rows[0][15].ToString());
report.SetParameterValue("od", prvi);
report.SetParameterValue("do", drugi);
// register the dataset
report.RegisterData(FDataSet);
//dizajn
report.Design();
// run the report
report.Show();
// free resources used by report
report.Dispose();
}
else
{
DataTable artikli = new DataTable();
artikli = izdani_bonovi.bonovi.CopyToDataTable();
//create dataset
DataSet FDataSet = new DataSet();
artikli.TableName = "Artikli";
FDataSet.Tables.Add(artikli);
// create report instance
Report report = new Report();
// load the existing report
System.Reflection.Assembly a = System.Reflection.Assembly.GetEntryAssembly();
string baseDir = System.IO.Path.GetDirectoryName(a.Location);
report.Load(baseDir + "/report/PregledBonova.frx");
report.SetParameterValue("partner", glPartner.Text);
report.SetParameterValue("naslov", "PREGLED IZDANIH BONOVA ZA:");
//report.SetParameterValue("iskoristeno", podaciZaReport.Rows[0][15].ToString());
report.SetParameterValue("od", prvi);
report.SetParameterValue("do", drugi);
// register the dataset
示例3: reportOznaceni
private void reportOznaceni()
{
if (dgPodaci.RowCount > 0)
{
try
{
table = new DataTable();
napunipotvrdjeneZaPredajuUDataset();
string OD = Convert.ToDateTime(dtpOD.EditValue).ToString("dd.MM.yyyy");
string DO = Convert.ToDateTime(dtpDO.EditValue).ToString("dd.MM.yyyy");
//create dataset
DataSet FDataSet = new DataSet();
table.TableName = "Artikli";
FDataSet.Tables.Add(table);
// create report instance
Report report = new Report();
// load the existing report
System.Reflection.Assembly a = System.Reflection.Assembly.GetEntryAssembly();
string baseDir = System.IO.Path.GetDirectoryName(a.Location);
report.Load(baseDir + "/report/Knjizenje.frx");
report.SetParameterValue("datumod", OD);
report.SetParameterValue("datumdo", DO);
report.SetParameterValue("datumPredaje", DateTime.Now.Date.ToString("dd.MM.yyyy"));
// register the dataset
report.RegisterData(FDataSet);
//dizajn
report.Design();
// run the report
report.Show();
// free resources used by report
report.Dispose();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
}
示例4: _btnDesign_Click
private void _btnDesign_Click(object sender, EventArgs e)
{
if (Save())
{
try
{
using (Report report = new Report())
{
PrepareReport(report);
report.Design(true);
}
}
catch (System.Exception ex)
{
MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}