.NET2.0 Base Class Library 系列(五)正则表达式

  1. use what namespace
    1using System.Text.RegularExpressions;

  2. load file into richtextbox
     1private System.Windows.Forms.RichTextBox inputText;
     2private void LoadTextFile()
     3{
     4string file = Path.Combine(Application.StartupPath, "Test.txt");
     5
     6if(File.Exists(file))
     7{
     8inputText.Text = File.ReadAllText(file);
     9}

    10}

posted @ 2007-12-04 11:13  许晓光  阅读(226)  评论(1)    收藏  举报