0

I have one windows utility which opens word document, extract data out of it and generate another word document using that data.

Now my problem is that this windows exe is working fine directly on command prompt, but if I call this exe through jenkins, i.e. build step "Execute windows batch command" it gives error, it is not able to open word document so utlity exists with error.

I have tried other options also like calling exe from pom file, and from batch file. every time it gives me same error. My tomcat service is running with the same user from which I am login to windows.

Any guidance on this topic will helpful.

Mark O'Connor
  • 76,015
  • 10
  • 139
  • 185
Pravin Virkud
  • 105
  • 3
  • 9
  • If you are running Jenkins as service then stop that service and open a command line window. Then launch Jenkins from that window. Let us know if that fixes the issue. – NotAgain May 25 '15 at 06:23

3 Answers3

1

You have to add "Desktop" folder in BOTH locations: C:\Windows\System32\config\systemprofile\Desktop and C:\Windows\SysWOW64\config\systemprofile\Desktop

sero
  • 161
  • 2
  • 11
0

Jenkins is not able to manage such application with a GUI as Tomcat is launched with a Windows service.

One option is to try to check this option on your Windows service: "Allow service to interact with desktop"

If it doesn't solve your problem, I'm not sure you will find a solution :(

Bruno Lavit
  • 10,184
  • 2
  • 32
  • 38
0

Create an empty directory "Desktop" in

C:\Windows\SysWOW64\config\systemprofile\

this solved the issue.

I guess this is problem with user rights for the desktop folder under users directory. The user by which tomcat service is running.

Pravin Virkud
  • 105
  • 3
  • 9