0

I am trying to open an excel file for processing using batch. The code I run on batch is correctly opening the file. The problem is when I try to trigger the same batch file remotely using Jenkins(I have a windows slave). The Jenkins job gets stuck infinitely there after running the command. It does nothing, just shows a message on the screen that says: "A program running on this computer is trying to display a message."[can't post image because of low reputation], and nothing more.

On clicking view message you get a message that Excel cannot open this file because of the following reasons. which is, i know nothing but a false alarm. How can I modify batch command or Jenkins job or something else on the virtual machine to make the code run?

This is my current command:
"C:\Program Files\Microsoft Office\Office15\EXCEL" /r "C:\file_name.xlsm"

mpalanco
  • 12,960
  • 2
  • 59
  • 67
rrawat
  • 1,071
  • 1
  • 15
  • 29

1 Answers1

0

The solution that worked for me was to create a folder named "Desktop" in system32 and SysWow64 (windows 7 64 bit)
C:\Windows\System32\config\systemprofile
C:\Windows\SysWOW64\config\systemprofile

so the full path will be:
C:\Windows\SysWOW64\config\systemprofile\Desktop C:\Windows\System32\config\systemprofile\Desktop

IIf this doesn't work, you can check the solution by Slav: Open Excel on Jenkins CI. it pointed me in the right direction

Community
  • 1
  • 1
rrawat
  • 1,071
  • 1
  • 15
  • 29