Forward and Backward Slashes in filepaths

In my project, I had been using data that I stored on dropbox.

Recently I started working on another computer and this posed a problem as my filepath changed to the

c\Users\*ANewUserName*\... 

So I tried to put the data folder within my project. This is when I realized that my project runs through the debug fulder and just saying "DataFolder\" referenced the debug folder. So I looked around on the internet and used "..\..\DataFolder\" to successfully locate files in the projects main folder.

So how exactly does this work?

by pope_says via /r/csharp

Leave a Reply