1
General / Re: Reason: Unable to open file
« on: July 05, 2021, 07:55:29 am »
I don't know if the working directory is the issue because I've tried the full location of the file too and it gave the same error, and I am sure that's the file's
But if that is the issue how can I change the working directory?
sf::RenderWindow window(sf::VideoMode(800, 800), "Chess"); //calls a window
window.setVerticalSyncEnabled(true);
sf::Texture t1;
t1.loadFromFile("C:/Users/jagdr/Downloads/Code/SFML Chess/Debug/Images/board.jpg");
sf::Sprite board(t1);
name.window.setVerticalSyncEnabled(true);
sf::Texture t1;
t1.loadFromFile("C:/Users/jagdr/Downloads/Code/SFML Chess/Debug/Images/board.jpg");
sf::Sprite board(t1);
But if that is the issue how can I change the working directory?