Ok, so my answer is a little lame, not what I wanted, but it works. I changed my GetMonthly signature to accept string input. Then I convert them in DateTime to the body of the method. It looks like I can check the legitimacy of DateTime in SSRS as a parameter which, since the WCF service recognizes in XML, is text. Thus, error checking for legal date refers to SSRS, but the string will be converted to .NET System.DateTime. I really don't like this answer, but it works.
public List<fMonthly_Result> GetMonthlyData2(string aStart, string aEnd) { using (SSRSReportsEntities re = new SSRSReportsEntities()) { DateTime dstart = DateTime.Parse(aStart); DateTime dend = DateTime.Parse(aEnd); return re.fMonthly(dstart, dend, null).ToList(); } }
Now this will work if I first set the parameters and match them with existing parameters defined in the draft report:
< Query> < Method Name="GetMonthlyData" Namespace="http://tempuri.org/"> < Parameters> < Parameter Name="aStart"></Parameter> < Parameter Name="aEnd"></Parameter> </Parameters> </Method> < SoapAction> http://tempuri.org/IReportingService/GetMonthlyData </SoapAction> </Query>
source share