注册 登录
  • 欢迎访问开心洋葱网站,在线教程,推荐使用最新版火狐浏览器和Chrome浏览器访问本网站,欢迎加入开心洋葱 QQ群
  • 为方便开心洋葱网用户,开心洋葱官网已经开启复制功能!
  • 欢迎访问开心洋葱网站,手机也能访问哦~欢迎加入开心洋葱多维思维学习平台 QQ群
  • 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏开心洋葱吧~~~~~~~~~~~~~!
  • 感谢各位客官的到来,小站的已经免费运营了15年头了,如果您觉着好,看着文章写的不错,还请看官给小站打个赏~~~~~~~~~~~~~!

C#对IIS进行操作的代码

C#对IIS进行操作的代码
这段代码是一个IIS操作类,可以最IIS进行站点的添加、删除、修改等操作//IISHelper.csusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Text.RegularExpressions;us……继续阅读 »

水墨上仙 5年前 (2021-03-14) 2104浏览 2883个赞

C#的类索引器

C#的类索引器
本代码创建了一个类的索引器用来访问类,就像访问数组一样using System.Collections.Generic;...class Client{ private Dictionary<int, string> invoices = new Dictionary<int, string>(); ……继续阅读 »

水墨上仙 5年前 (2021-03-14) 2056浏览 1868个赞

C# 计算素数

C# 计算素数
这段代码通过BitArray来计算素数using System.Collections;...const int LAST_CANDIDATE = 1000;int primes = 0;BitArray candidates = new BitArray (LAST_CANDIDATE, true); for (int i = 2; i ……继续阅读 »

水墨上仙 5年前 (2021-03-14) 3113浏览 2917个赞

C#验证ip地址

C#验证ip地址
C#代码验证IP地址,包含格式和是否超过255的限制/// <summary> /// Check IP Address, will accept 0.0.0.0 as a valid IP /// </summary> /// <param name="strIP……继续阅读 »

水墨上仙 5年前 (2021-03-14) 1937浏览 410个赞

C# 生成随机数的代码片段

C# 生成随机数的代码片段
下面的c#代码片段显示产生随机数输出到控制台。RandomNumber函数的第一个参数为生成的随机数的最小值。第二个参数是最大值+ 1。using System; class Program{ private Random random = new Random(); private int RandomNumber (int ……继续阅读 »

水墨上仙 5年前 (2021-03-14) 1953浏览 1291个赞

C# MD5计算

C# MD5计算
本范例演示了C#如何对一个给定的字符串进行MD5加密/// <summary>/// Calculates a MD5 hash from the given string and uses the given/// encoding./// </summary>/// <param name="Inpu……继续阅读 »

水墨上仙 5年前 (2021-03-14) 1432浏览 248个赞

C#解冻Windows UI界面的方法

C#解冻Windows UI界面的方法
本范例演示了C#开发GUI程序时如何避免一个超长处理过程占用全部资源,导致界面不能响应用户事件的方法// You need the Threading library to use the // "Thread.Sleep" function// using System.Threading; // This boolean……继续阅读 »

水墨上仙 5年前 (2021-03-14) 3243浏览 1401个赞

加载中……