Load stimulsoft report
Posted: Mon Nov 02, 2015 8:51 am
am new to stimulsoft am using stimulsoft as report tool in c# ,i have class and below are codes under class
and below are my codes under button click event
when i load my report i get a blank report kindly help me
Code: Select all
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SaccoClassLibrary1;
using Class1;
using Stimulsoft.Report;
namespace Sacco
{
class SaccoReport
{
private Saccomembers Svcclient = new Saccomembers();
public class Vehiclelist
{
private List<VehicleType> tvehicles = new List<VehicleType>();
private List<CompanyType> company = new List<CompanyType>();
public List<VehicleType> vehicle
{
get { return tvehicles; }
set { tvehicles = value; }
}
public Vehiclelist(List<VehicleType> VEHICLE)
{
vehicle = VEHICLE;
}
}
}
}
Code: Select all
List<VehicleType> tvehicles = new List<VehicleType>();
List<SavingType> saves = new List<SavingType>();
tvehicles = svclient.Getvehicles();
if (tvehicles.Count > 0)
{
StiReport report = new StiReport();
report.Load(Application.StartupPath + "\\vehicle.mrt");
report.ReportAuthor = "Cyrus";
report.ReportDescription = "Vehicles";
report.RegBusinessObject("Stocksales", new SaccoReport.Vehiclelist(tvehicles));
//report.RegBusinessObject("Sacco", svclient.Getvehicles());
report.Show(true);
}