迅速地在树视图中出现问题 [英] problem in treeview quikly

查看:71
本文介绍了迅速地在树视图中出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

谢谢我解决了我的问题

问题是关于treeview

Thanks i solved my problem

the quaestion was about treeview

推荐答案

看起来很简单的逻辑
1.读取数据文件中的每一行
2.用,分隔符分隔文本
3.打印第二个单词

代码示例为:
Looks like pretty straight forward logic
1. read each line in the data file
2. split the text with , separator
3. print the second word

Code sample is:
string dataFilename = "mydata.txt";
if (File.Exists(dataFilename))
{
    using (StreamReader sReader = new StreamReader(dataFilename))
    {
        string line = String.Empty;
        while ((line = sReader.ReadLine()) != null)
        {
            string[] words = line.Split(' ');
            Console.Writeline(words[1]);
        }
    }


这篇关于迅速地在树视图中出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆