Skip to content

Report between months As Jun-2014 to sept-2015.

Abhinav Kansal

Asked Jun 6, 2015, 12:46 AM EDT3 answers
Share
LinkedInX
hiii
 
I want a report between months. As Jun-2014 to sept-2015 on button click.
& if i change month from 1 combobox & 2 combobox then report will also change.
& I am not sure how to do it.
Pls anyone can help me......'
 
THNX

3 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • Manoj Bhoir
    0
    Hi,
     
    You can pass parameter to your Report using ReportParameter Class.
     
    Let's say you want report from 1-Jun-2015 to 30-Sep-2015.
     
    Your SQL query for report should be like this :
     
    Select * from TableName
    Where DateColumn=@FromDate And DateColumn=@ToDate
     
    I hope you know how to create  parameterised Report.
     
    You can pass values for these parameters using  this code :
     
    Java
    ReportParameter reportParam1, reportParam2;
                    List<ReportParameter> paralist = new List<ReportParameter>();
                    reportParam1 = new ReportParameter("FromDate", "");
                    reportParam2 = new ReportParameter("ToDate", "");
                    paralist.Add(reportParam1);
                    paralist.Add(reportParam2);
                    reportViewer.ServerReport.SetParameters(paralist);
    0
  • 0
    I told u earlier tht i only want month wise report.means just select month name in 1st combo box & then again month name in 2nd combo box & it show me report between these months.
     
     
    AS From "Jan-2015" To  "May-2015"
     
    I store month data into DB as jan-2015,feb-2015,march-2015......................
    0
  • 0
    Code must be in C#.net
    i stored data into DB table as entry from January month as Jan-2015
     
    & then in February month data as Feb-2015...........
     
    thts it i only want filter my report according to these feeded months..
     
    this will be in text format....... i don't want report date wise coz i didn't enter date into my form as
    1/1/2015. i only feed month & year name as Jan-2015,Feb-2015,mar-2015,Apr-2015 etc.....
     
    Help me buddy.........
    0