web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Microsoft.Office.Interop.Excel in Batch

(0) ShareShare
ReportReport
Posted on by

I have search this to death and cant find a solution.  I need to create an excel file in batch and when I run the class that is running on server (and the method syntax is: server static) I get the error message that it could not load the file or assembly "Microsoft.Office.Interop.Excel".  If I run it locally (client mode) on the AOS server it runs fine so I know the assembly is installed and working correctly - its just that when running in the batch it cant find it.  If anybody has anything to offer on this it would be greatly appreciated.

Thanks,

Rick

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at

    Probably because the dll-file is 32 bit and the ax32serv.exe is 64 bit.

    Regards,

    Kjetil

  • kidder22 Profile Picture
    on at

    Thanks for the reply.  So if I install the 64 bit version of office (excel) you are thinking that would fix this problem?

  • kidder22 Profile Picture
    on at

    I installed the 64 bit version of office and I'm still receiving the same error.  If anybody else has any ideas it would be greatly appreciated.

  • Suggested answer
    Community Member Profile Picture
    on at

    Unfortunately you cannot achieve this, excel object cannot be initialized on server side hence you cannot import/export excel file in code which is running on server side.

  • Denis Macchinetti Profile Picture
    16,444 on at

    Hi

    Take a look to this post

    You can create an Excel document from a batch job where Excel is not installed using Open XML.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Priya_K Profile Picture

Priya_K 4

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans