I've been working on a project lately & I'm totally new to .NET so excuse me for that -.-
I was wondering how to replace the value of a string with the content of a .txt file. This is what I've got so far but it won't work -_- Instead of showing me the content of the file it shows me the path as I wrote it.
string replacedString = string1.Replace(string1, Environment.CurrentDirectory + @"\scripts\StickyNotes\Server Website.txt");
The string1 was in fact a string array that I converted. But I don't think this should make any difference because it's equal to a string now. Btw this string contains now a value equal to 1 line of text. So what the .txt file should do is overwriting that line with the new value.
Maybe there isn't a direct option to do that so what I'm asking you is maybe a little complicated -.-
Because I'm new to C# coding could you also explain what the code of your answer is supposed to do xP
Thanx for taking your time!!
Edit: I also wan't to note that I'm actually working in a public StickyNotes(). So no static class.