Quantcast
Channel: Microsoft Dynamics AX Forum - Recent Threads
Viewing all articles
Browse latest Browse all 175888

Sending SSRS report via email in Batch workaround in AX 2012 R3

$
0
0

My customer is trying to run a standard SSRS report in batch and email it to users in Microsoft Excel format.  The batch job to do this ran and ended with no errors.  The e-mail distributor batch job also ran and ended with no errors.  But no email is ever sent. This process works in non-batch.

I then found the workaround described in detail in this blog -

https://community.dynamics.com/ax/b/axdeveloperconnection/archive/2014/08/14/ssrs-reports-won-39-t-email-as-attachment-in-batch

The workaround is to enter a valid email address in the cc'. 

I also had to add both the AOS and BCProxy account as users with sys admin role in AX otherwise the email will not get sent and you will see this error in your application event log on your AOS server -

Object Server 01: An error has occurred in the services framework. Method: AifMessageInspector::AfterReceiveRequest. Error: System.ServiceModel.FaultException: Failed to logon to Microsoft Dynamics AX.

at Microsoft.Dynamics.Ax.Services.AxServiceOperationContext.InitializeSession()

at Microsoft.Dynamics.Ax.Services.AxServiceOperationContext.InitializeContext()

at Microsoft.Dynamics.Ax.Services.AxServiceOperationContext.Attach(OperationContext owner)

at System.ServiceModel.ExtensionCollection`1.InsertItem(Int32 index, IExtension`1 item)

at System.Collections.Generic.SynchronizedCollection`1.Add(T item)

at Microsoft.Dynamics.Ax.Services.AifMessageInspector.AfterReceiveRequest(Message& request, IClientChannel channel, InstanceContext instanceContext)

Adding both the accounts in AX as just users, got rid of the above error in Event viewer but the email will not get sent.

So to get the SSRS report to get sent via email in batch in AX 2012 R3, I had to -

- add the AOS service account and BC proxy account into AX as users and gave them Sys admin role

- made sure to enter a valid cc' in the email.

 

I am wondering if Microsoft has an update to the issue reported in the blog (link above).


Viewing all articles
Browse latest Browse all 175888

Trending Articles