I am pulling my hair out trying to get the code below to work in a method bpm on a Kinetic client. The message I have in my code below displays nothing. It shows the report complete in the system monitor but no report in the Reports tab of the system monitor and no report pops up. I believe that is because it need my WorkstationID to display/preview the report. If I generate only it shows in the Reports tab and I can preview it. Also, when I look at the Workstation for my user profile, it returns, No Data Found.
Please help!
Thanks,
Richard
string workstationid = Session.WorkstationID;
this.PublishInfoMessage(workstationid,Ice.Common.BusinessObjectMessageType.Information, Ice.Bpm.InfoMessageDisplayMode.Individual,"","");
int quoteNum = Convert.ToInt32(callContextBpmData.Number01);
using (Ice.Contracts.DynamicReportSvcContract dynamicReport = Ice.Assemblies.ServiceRenderer.GetService<Ice.Contracts.DynamicReportSvcContract>(Db))
{
using( Erp.Contracts.QuotFormSvcContract QuotForm = Ice.Assemblies.ServiceRenderer.GetService<Erp.Contracts.QuotFormSvcContract>(Db) )
{
var baqRptDS = QuotForm.GetNewParameters();
baqRptDS.QuoteFormParam[0].AutoAction = "SSRSPreview";
baqRptDS.QuoteFormParam[0].AttachmentType = "PDF";
baqRptDS.QuoteFormParam[0].WorkstationID = workstationid;
baqRptDS.QuoteFormParam[0].SSRSRenderFormat = "PDF";
baqRptDS.QuoteFormParam[0].RecurringTask = false;
baqRptDS.QuoteFormParam[0].SSRSEnableRouting = false;
baqRptDS.QuoteFormParam[0].ArchiveCode = 0;
baqRptDS.QuoteFormParam[0].AgentSchedNum = 0;
baqRptDS.QuoteFormParam[0].AgentID = "System Task Agent";
baqRptDS.QuoteFormParam[0].ReportStyleNum = 1008;
baqRptDS.QuoteFormParam[0].AgentTaskNum = 0;
baqRptDS.QuoteFormParam[0].QuoteNum = quoteNum;
baqRptDS.QuoteFormParam[0].RowMod = "A";
QuotForm.SubmitToAgent(baqRptDS, "System Task Agent", 0, 0, "Erp.Rpt.QuotForm;QuotForm");