Read from output file in installed WCF service
Posted
by fishiefishie
on Stack Overflow
See other posts from Stack Overflow
or by fishiefishie
Published on 2010-05-12T00:42:05Z
Indexed on
2010/05/12
0:44 UTC
Read the original article
Hit count: 240
I included a text file as output in a WCF set up project. The text file is correctly located in the same folder with the dll, exe, and config file after the project is installed (C:\Program Files\KLTesting\KLTestApp). However when the program tries to read it, it looks under "C:\Windows\system32", what's the correct way to find & read it?
I have
string a = Directory.GetCurrentDirectory();
a += "/R0303.txt";
string content = File.ReadAllText(a);
Thanks.
© Stack Overflow or respective owner