易截截图软件、单文件、免安装、纯绿色、仅160KB

asp.net准确截取文本长度(取得标题的字符数)

asp.net中自带的CutString只能截取字符数量的长度,但中英文字符数有差异,一个中文字等同于二个英文字符的宽度,这样对截取后的效果不理想.使用以下的方法就能解决.
//调用方法
string title=BLL.CutStr.CutString("标题",10);using System;
using System.Collections.Generic;
using System.Text;
namespace BLL
{
    public  class CutStr
    {
        public static string  CutString(string str, int length)
        {
            if (str == "" )
            {
                str = "没有信息";
            }
            else
            {
                int i = 0, j = 0;
                foreach (char chr in str)
                {
                    if ((int)chr > 127)
                    {
                        i += 2;
                    }
                    else
      &nbs


相关文档:

Asp.net图片滚动


<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="图片滑动.aspx.cs" Inherits="ASP.net.图片滑动" %>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
    ......

ASP.NET快捷方式大全

快捷键 功能
CTRL + SHIFT + B生成解决方案
CTRL + F7 生成编译
CTRL + O 打开文件
CTRL + SHIFT + O打开项目
CTRL + SHIFT + C显示类视图窗口
F4 显示属性窗口
SHIFT + F4显示项目属性窗口
CTRL + SHIFT + E显示资源视图
F12 转到定义
CTRL + F12转到声明
CTRL + ALT + J对象浏览
CTRL + ALT + F1 ......

C# asp.net如何使用MD5加密,解密

using System;
using System.Collections.Generic;
using System.Text;
using System.Security.Cryptography;namespace md5
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(UserMd5("8"));
Console.WriteLine(GetMd5Str("8"));
}
/**//// &lt;summary&gt;
/// MD5 16位加密 ......

ASP.net 4.0 针对SEO的改进

搜索引擎优化对任何面向公众的网站来说都非常重要,ASP.net 4.0 为此就做了大量改造。这些改进包括如下:
301
永久性重定向
随着时间的迁移,网站的一些页面地址会发生变化,这会导致搜索引擎收录的链接地址、用户收藏的地址失
效。Response.Redirect() 就是解决这个问题的。但是Response.Redirect 有以下问题:
Respo ......

Online active users counter in ASP.NET


Online active users counter in ASP.NET
With this tool which is written for ASP.NET, it is possible to count the number of online users, members and guest users in web sites.
Installation
The tool installation is very simple and only takes a few minutes.
Step one - Add Reference:
After downlo ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号