I have a problem with my function
public class PS3
{
public static void restoreAllClassesNames(string A, string B, string C/*, string A1, string B1, string C1, string A2, string B2, string C2, string A3, string B3, string C3, string A4, string B4, string C4*/)
{
A = returnLine("a.txt", 0);
B = returnLine("a.txt", 1);
C = returnLine("a.txt", 2);
}
public static string returnLine(string fileName, int line)
{
StreamReader SR = new StreamReader(fileName);
List<string> myList = new List<string>();
string linePath;
while ((linePath = SR.ReadLine()) != null)
myList.Add(linePath);
return myList[line];
}
So, when I am do this :
Functions.PS3.restoreAllClassesNames(textBox1.Text, textBox2.Text, textBox3.Text);
My textbox1 , 2 & 3 contains nothing, yet it should work