Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Relative paths in Visual Studio

Tags:

I'm working in Visual Studio 2005 and have added a text file that needs to be parsed by right-clicking the project in the solution explorer and add --> new item. This places the .txt file to the project folder. The debug .exe file is in the /bin/debug folder.

How do I properly point to the txt file from code using relative paths that will properly resolve being two folders back, while also resolving to be in the same folder after the solution is published?