I started developing a card game with XNA, but I had problems reading all the cards inside the Cards directory, which is inside the Content.
I tried the following code:
string[] nomeCartas = Directory.GetFiles(@"Cards");
But with this I got an error stating that it is impossible to find part of the path:
Do caminho National Board of Trade Oversight "C: \ Users \ Seraph \ Documents \ Visual Studio 2010 \ Projects \ JogoSuecaOnline \ JogoSuecaOnline \ JogoSuecaOnline \ Bin \ x86 \ Debug \ cards \".
I checked this path and it is wrong, the correct path should be:
C: \ Users \ Seraphim \ Documents \ Visual Studio 2010 \ Projects \ JogoSuecaOnline \ JogoSuecaOnline \ JogoSuecaOnline \ Bin \ x86 \ Debug \ Content \ Cards \
Is there any other way to read the contents of a directory using XNA or how to fix it?
source share