Issues with Visual Studio 2015

MrM21632

Estimable
Jul 20, 2015
3
0
4,510
I have been having issues with Visual Studio 2015. I am not new to using Visual Studio, but it has been a while since I've used it. I am currently trying to build a C++ Solution with SDL that simply creates a window. Here are all of the details I can provide regarding how the project is set up:
1) The libraries, .dll's, and header files have all been set up correctly.
2) The solution builds correctly.
3) It is in Debug mode.
4) With all of this in mind, it still gives the following error when I press F5:

Unable to start program 'C:\[File Path]\[Solution].exe'.
The system cannot find the file specified.

Sure enough, when I check, it isn't there. Does anyone know how I can fix this?
 

MrM21632

Estimable
Jul 20, 2015
3
0
4,510


I'm not sure how that works, but I have tried to get this to work since posting the question. For some reason, it seems to work now - I Build the solution, then the .exe is in the Debug folder. All I typed out this time was the simplest program I could think of:

#include <iostream>
int main()
{
return 0;
}

This worked. What I'm now having an issue with is trying to get SDL to work:
1) I have set it up correctly - I know this because it does say the build was successful and there are no error messages.
2) It is still in Debug Mode.
3) With all of this in mind, it does not create a .exe file.

This is what I am trying to compile, if it may help:

#include "SDL.h" /* All SDL App's need this */
#include <stdio.h>

int main(int argc, char *argv[]) {

printf("Initializing SDL.\n");

/* Initialize defaults, Video and Audio */
if ((SDL_Init(SDL_INIT_VIDEO | SDL_INIT_AUDIO) == -1)) {
printf("Could not initialize SDL: %s.\n", SDL_GetError());
exit(-1);
}

printf("SDL initialized.\n");

printf("Quiting SDL.\n");

/* Shutdown all subsystems */
SDL_Quit();

printf("Quiting....\n");

exit(0);
}#include "SDL.h" /* All SDL App's need this */
#include <stdio.h>

int main(int argc, char *argv[]) {

printf("Initializing SDL.\n");

/* Initialize defaults, Video and Audio */
if ((SDL_Init(SDL_INIT_VIDEO | SDL_INIT_AUDIO) == -1)) {
printf("Could not initialize SDL: %s.\n", SDL_GetError());
exit(-1);
}

printf("SDL initialized.\n");

printf("Quiting SDL.\n");

/* Shutdown all subsystems */
SDL_Quit();

printf("Quiting....\n");

exit(0);
}
 

MrM21632

Estimable
Jul 20, 2015
3
0
4,510


I attempted this and it didn't work - I placed in the same folder as the Project and both of the Debug folders (I wasn't sure which one you were talking about - Visual Studio creates two debug folders, so I threw it in both).