using Stimulsoft Reports.Net 2010.1
I have a report and an asp.net web page
the report loads perfectly
and export goes fine
I have a drop down list that regenerate the report based on selection
every time I select another item from the list , the report renders fine based on selection
but if I clicked export as PDF it export the first initial created report
here is my code for generating the report:
Code: Select all
void LoadReport()
{
DataSet ds = new DataSet();
SqlDataAdapter ada = new SqlDataAdapter("select * from [vwTimeTable] where SEID=" + ddlSEID.SelectedValue, ConfigurationManager.ConnectionStrings["netTiersConnectionString"].ConnectionString);
ada.Fill(ds);
ds.DataSetName = "Connection";
ds.Tables[0].TableName = "vwTimeTable";
StiReport rtp = new StiReport();
rtp.Load(Server.MapPath("~/Reports/rptTimeTable.mrt"));
rtp.Dictionary.Databases.Clear();
rtp.DataSources.Clear();
rtp.RegData("vwTimeTable", ds.Tables["vwTimeTable"]);
rtp.RegData("Connection", ds);
rtp.Dictionary.Synchronize();
StiWebViewer1.Report = rtp;
}