I'm trying to open a text file in a program I've created but it won't work unless I specify it as an absolute file path. I can't seem to make a relative path name.
Sophiron -2 Newbie Poster
Recommended Answers
Jump to PostIf you have added the text file to a project and you can see it in the solution explorer then you need to click on the text file and set the build action to content and copyToOutput = copyifnewer or copyalways. You can then open it with
All 3 Replies
adam_k 239 Master Poster

Unhnd_Exception
Sophiron -2 Newbie Poster
Unhnd_Exception commented: Your code looks fine to me. What's the problem. -2
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.