我有这门课:
public static class CsvWriter
{
private static StreamWriter _writer = new StreamWriter(@"c:\temp\ssis_list.csv");
public static StreamWriter Writer
{
get { return _writer; }
}
}
这是从另一个类调用的
class Program
{
...
static void GetConnections(string path,string pkgname,string server)
{
_writer.WriteLine(myLine);
}
}
哪个有这个错误
The name '_writer' does not exist in the current context
我怎么修这个?