2016-09-07 3 views

답변

-1

는 "사용"을 사용하여 시도 돕는

Dim sb AS new StringBuilder() 
    .../... 
Dim filePath = Server.MapPath("/my/path") & "mytextfile.txt" 
Dim w As StreamWriter 
w = File.CreateText(filePath) 
w.Write(sb.ToString()) 
w.Close() 

감사합니다. 파일을 업데이트해야 할 때마다이 네 줄을 삽입하면됩니다.

Using w As StreamWriter(File.CreateText(filePath)) 
w.Write(sb.ToString()) 
w.Dispose() 
End Using 
관련 문제