filter class with stimulsoft

Stimulsoft Reports.WEB discussion
Post Reply
arfaie
Posts: 5
Joined: Sat Sep 05, 2015 10:34 am

filter class with stimulsoft

Post by arfaie »

I designed a report
in this report there's Two types of filters first one for filtering Date via two text box and other one for filtering class type via dropdown. both of them work correctly in stimulsoft designer but dropdown filtering dosen't work in asp.net web page
plz help me
[img]
http://8pic.ir/images/0klmctx0poxzfud6pjy0.png
[/img]

Code: Select all

public partial class Report : System.Web.UI.Page
{
    EsmailEntities db = new EsmailEntities();
    protected void Page_Load(object sender, EventArgs e)
    {
        DrpGrpPro();
    }

    protected void Button1_Click(object sender, EventArgs e)
    {
        string con = ConfigurationManager.ConnectionStrings["EsmailEntities"].ConnectionString;
        string serverlocation = HttpContext.Current.Server.MapPath(string.Empty);
        StiReport report = new StiReport();
        report.Dictionary.Databases.Add(new Stimulsoft.Report.Dictionary.StiSqlDatabase("connection", con));
        report.Load(serverlocation + "\\Reports\\ReportWithFiltermrt.mrt");
        report.Dictionary.Variables["SC"].Value = DropDownList1.SelectedItem.Value;
        report.Dictionary.Variables["FromDate"].Value = txtFromDate.Text;
        report.Dictionary.Variables["ToDate"].Value = txtToData.Text;
    }
    void DrpGrpPro()
    {

        DropDownList1.DataTextField = "ClassName";
        DropDownList1.DataValueField = "ClassId";
        DropDownList1.DataSource = db.TblClass.ToList();
        DropDownList1.DataBind();
        DropDownList1.Items.Insert(0, new ListItem("انتخاب کنید", "0"));


    }
}
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: filter class with stimulsoft

Post by HighAley »

Hello.

Which version of our product do you use?
Please, send us your report template with link on this page to support@stimulsoft.com.

Thank you.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: filter class with stimulsoft

Post by HighAley »

Hello.

Which version of our product do you use?
Please, send us more detailed description of the issue with link on this page to support@stimulsoft.com.

Thank you.
Post Reply