随笔分类 -  .net技术

丶对字符串进行加密和解密
摘要:效果图:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example46{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } pr... 阅读全文
posted @ 2011-10-23 12:33 C#_初学者 阅读(282) 评论(0) 推荐(0)
丶获取字符串中汉字的个数
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.Text.RegularExpressions;namespace Example44{ public partial class Form1 : Form { public Form1() { ... 阅读全文
posted @ 2011-10-21 00:21 C#_初学者 阅读(337) 评论(0) 推荐(0)
丶从字符串中分离文件路径、文件名和扩展名
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example43{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-20 01:18 C#_初学者 阅读(1892) 评论(0) 推荐(0)
丶去除字符串中的所有空格
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.Collections; // 引用 IEnumeratornamespace Example42{ public partial class Form1 : Form { public Form1() {... 阅读全文
posted @ 2011-10-20 00:24 C#_初学者 阅读(285) 评论(0) 推荐(0)
丶将字符串的每个字符进行颠倒输出
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example41{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-19 22:51 C#_初学者 阅读(562) 评论(0) 推荐(0)
丶根据标点符号对字符串进行分行
摘要:// 效果图 --------using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example39{ public partial class Form1 : Form { public Form1() { InitializeComponent();... 阅读全文
posted @ 2011-10-18 23:43 C#_初学者 阅读(1286) 评论(0) 推荐(0)
丶汉字与区位码的转换
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example37{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-18 21:50 C#_初学者 阅读(508) 评论(0) 推荐(0)
丶字母与ASCII码的转换
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example36{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-18 21:25 C#_初学者 阅读(707) 评论(0) 推荐(0)
丶将字母全部转换为大写或小写
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example35{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-18 20:32 C#_初学者 阅读(816) 评论(0) 推荐(0)
丶使用goto语句在数组中搜索指定图书
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example34{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } string... 阅读全文
posted @ 2011-10-18 01:29 C#_初学者 阅读(382) 评论(0) 推荐(0)
丶制作一个数字猜猜看小游戏
摘要:效果图 ----using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.Threading; //用到了线程namespace Example33{ public partial class Form1 : Form { public Form1() { ... 阅读全文
posted @ 2011-10-17 23:31 C#_初学者 阅读(2204) 评论(0) 推荐(0)
丶递归算法的经典面试题
摘要:1,1,2,3,5,8,13,21,34....... 要求用递归的方法算出 第 30 个数是多少!using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example32{ public partial class Form1 : Form { public Form1... 阅读全文
posted @ 2011-10-17 21:48 C#_初学者 阅读(1230) 评论(0) 推荐(0)
丶循环向控制台中输入 内容
摘要:using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace Example31{ class Program { static void Main(string[] args) { Console.Title = "循环向控制台中输入内容"; //定义控制台标题 Console.WindowWidth = 30; //窗体宽度 Console.WindowHeight = 2; //窗体高度 ... 阅读全文
posted @ 2011-10-17 01:34 C#_初学者 阅读(865) 评论(0) 推荐(0)
丶使用as关键字将对象转换为指定类型
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.IO;namespace Example26{ public partial class Form1 : Form { public Form1() { InitializeComponent()... 阅读全文
posted @ 2011-10-17 01:33 C#_初学者 阅读(268) 评论(0) 推荐(0)
丶使用is关键字判断对象是否与指定类型兼容
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example24{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-17 01:32 C#_初学者 阅读(280) 评论(0) 推荐(0)
丶使用 typeof 关键字获取类的内部结构
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.Reflection; // MethodInfo 需要引用namespace Example23{ public partial class Form1 : Form { public Form1() {... 阅读全文
posted @ 2011-10-17 01:27 C#_初学者 阅读(219) 评论(0) 推荐(0)
丶使用 checked 关键字处理 溢出 错误信息
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example22{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-17 01:25 C#_初学者 阅读(307) 评论(0) 推荐(0)
丶使用条件运算符判断指定年份是不是闰年
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example20{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } privat... 阅读全文
posted @ 2011-10-17 01:22 C#_初学者 阅读(768) 评论(1) 推荐(0)
丶巧用位移运算符获取汉字编码值
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace Example019{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } priva... 阅读全文
posted @ 2011-10-17 01:06 C#_初学者 阅读(647) 评论(0) 推荐(0)