1

SUMMARIZE THE PROBLEM:

I'm using Visual Studio 2015 for some project and what I'm trying to do is to run a batch file which is going to open an app(whatever app). The problem is that the VS2015 is going to get stuck in the build process until my app is going to be close.

The batch is working perfectly fine. You could try this just with a batch something like:

start notepad.exe

Or whatever you want, it doesn't really matter what's the application you are going to open here.

WHAT I'VE TRIED:

I've tried already some alternatives like...

  1. Run the bat from the post-build event with "call", "start" or with none of them.
  2. I've added "exit 0" on the end of the file(batch)
  3. Also, I've tried to create 2 batch files. One was the original one and the second one was calling the first one. So I've added the second one at the post-build event. Nothing changes, of course.

WHAT I AM TRYING TO OBTAIN:

On the end, all that I'm trying to obtain is just a batch with is going to open an application after the build/rebuild of the project is done without getting stuck somewhere there.

enter image description here

It's going to stay in this "Build" process even though the build is "Build Succeed"

Community
  • 1
  • 1
cavaler12345
  • 367
  • 1
  • 5
  • 15

1 Answers1

0

Unfortunately I believe all processes spun off by the build have to be joined and returned successfully for VS to consider the build a success. Instead, is it possible in your use-case to attach the batch file to the execution step of your project? In the project settings you can modify the command line arguments to spin off your batch file before executing your project executable. Is there any issues with this approach?

I found this too, would this help: Visual Studio post build events stuck waiting for executable to finish before running app in debug mode

Bobby Tables
  • 191
  • 2
  • 15