C# modifing a string array in a foreach loop and changing the same array
<p>Maybe I asked this is a bad way so let me try to explain.</p>

<p>I have a <strong>public static string[]</strong></p>

<pre><code>public static string[] MyInfo {get;set;}
</code></pre>

<p>I set this via</p>

<pre><code>MyInfo = File.ReadAllLines(@"C:\myfile.txt");
</code></pre>

<p>What I want to do is a foreach on each of those lines and modify it based on x number of rules.  One the line has been modified change that exisiting line in MyInFo</p>

<p>so</p>

<pre><code>foreach(string myI in MyInfo)
{
string modifiedLine = formatLineHere(myI);
//return this to MyInfo somehow.

}
</code></pre>
