VB.NET
VB.net开发智能设备时,怎么将数据写入.TXT文本中啊! 急求代码! --------------------编程问答-------------------- 给你一个函数吧Public Sub savetxt(ByVal mystr As String, ByVal path As String)
Dim s As Stream
If Not File.Exists(path) Then
s = File.Create(path)
s.Close()
End If
Dim fs As FileStream = File.OpenWrite(path)
Dim sw As New StreamWriter(fs)
fs.Seek(0, SeekOrigin.End)
sw.WriteLine(mystr)
sw.Close()
fs.Close()
End Sub
其中mystr是要存的字符串,path是存储txt文件的路径
希望对你有用! --------------------编程问答-------------------- 智能设备不支持fileopen之类的函数啊
补充:.NET技术 , VB.NET