日期:2011-03-04  浏览次数:20436 次

using System;
using Microsoft.VisualBasic;
。。。。。。

          static void Main(string[] args)
             {
                    s = "ABCD123";
                    //Fully qualified use of Mid()
                    stringletters = Microsoft.VisualBasic.Strings.Mid(s,1,4);
                    //Can also just use the static function since
                    //we imported the namespace
                    stringnumbers = Strings.Mid(s,5,3);
                    Console.WriteLine(numbers + " " + letters);
                    Console.Read();
             }