C How to exit the command prompt -


I am trying to write a program in C that executes another program and even appears I do not give it, but the way I made the code for some reason does not stop at all, only when I press the red X button on the top right, if you know that it is, then here is the code I have used Hope you can help.

  # include & lt; Stdlib.h & gt; Int main () {system ("% appdata% / file.jar"); Exit (0); Return (0); }  

As you can see, I am not very skilled in this particular programming language.

OK This can only be done with a simple start or just a batch script here's an example Is:

  #include & lt; Stdlib.h & gt; Main () {system ("start% appdata% / file.jar"); Return (0); }  

is batch scripting:

  start% appdata% / file.jar  

I'm not quite Understand why it is necessary to be a complete binary, but it should solve your problem (believe it is Windows)

The author changed the path, it seems that editing credits in order to obtain. Updated with improvements.


Comments

Popular posts from this blog

import - Python ImportError: No module named wmi -

Editing Python Class in Shell and SQLAlchemy -

c# - MySQL Parameterized Select Query joining tables issue -