StreamWriter 建立一個新txt檔案
string path=“B\123.txt”;
if(File.Exists(path)=false)
{
StreamWriter sw=new StreamWriter(path,true,System.Text.Encoding>UTF8);
//把資料寫入txt文本流
sw.WriteLine(“小小小小啦啦啦啦啦啦”);
sw.CLose();
}
string path=“B\123.txt”;
if(File.Exists(path)=false)
{
StreamWriter sw=new StreamWriter(path,true,System.Text.Encoding>UTF8);
//把資料寫入txt文本流
sw.WriteLine(“小小小小啦啦啦啦啦啦”);
sw.CLose();
}