且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何从文本文件中读取数据

更新时间:2023-02-19 21:36:33

Quote:

想要为其添加脚本功能。

want to add script functionality to it.

您可以使用实际的脚本编程语言。例如,您可以使用VBScript。例如,请参阅 VB.NET Windows窗体中的VBScript - VB.NET | Dream.In.Code [ ^ ]

You could use an actual script programming language. For instance you could use VBScript. See, for instance VBScript In VB.NET Windows Form - VB.NET | Dream.In.Code[^]


使用 StreamReader类(System.IO) [ ^ ]这将允许您读取每一行。然后,您可以使用 String.Split方法(系统) [ ^ ]获取该行的单独部分。
Use the StreamReader Class (System.IO)[^] which will allow you to read each line. You can then use the String.Split Method (System)[^] to get the separate parts of the line.