国产99久久精品_欧美日本韩国一区二区_激情小说综合网_欧美一级二级视频_午夜av电影_日本久久精品视频

最新文章專題視頻專題問答1問答10問答100問答1000問答2000關鍵字專題1關鍵字專題50關鍵字專題500關鍵字專題1500TAG最新視頻文章推薦1 推薦3 推薦5 推薦7 推薦9 推薦11 推薦13 推薦15 推薦17 推薦19 推薦21 推薦23 推薦25 推薦27 推薦29 推薦31 推薦33 推薦35 推薦37視頻文章20視頻文章30視頻文章40視頻文章50視頻文章60 視頻文章70視頻文章80視頻文章90視頻文章100視頻文章120視頻文章140 視頻2關鍵字專題關鍵字專題tag2tag3文章專題文章專題2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章專題3
問答文章1 問答文章501 問答文章1001 問答文章1501 問答文章2001 問答文章2501 問答文章3001 問答文章3501 問答文章4001 問答文章4501 問答文章5001 問答文章5501 問答文章6001 問答文章6501 問答文章7001 問答文章7501 問答文章8001 問答文章8501 問答文章9001 問答文章9501
當前位置: 首頁 - 科技 - 知識百科 - 正文

asp.net中簡體轉繁體實現代碼

來源:懂視網 責編:小采 時間:2020-11-27 22:43:22
文檔

asp.net中簡體轉繁體實現代碼

asp.net中簡體轉繁體實現代碼:我還是直接貼例子在說明一下吧: 代碼如下://Form1.cs using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text;
推薦度:
導讀asp.net中簡體轉繁體實現代碼:我還是直接貼例子在說明一下吧: 代碼如下://Form1.cs using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text;

我還是直接貼例子在說明一下吧:
代碼如下:

//Form1.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using EncodeMy;
namespace TestEnCode
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
EncodeRobert edControl = new EncodeRobert();//創建一個簡繁轉換對象
txtResult.Text= edControl.SCTCConvert(ConvertType.Simplified, ConvertType.Traditional,txtSource.Text);//進行簡繁轉換
}
}
}

注意:using EncodeMy;并非.net自帶的類庫,在Encode.dll中。要引用一下的。
請到http://download.csdn.net/source/617532
http://download.csdn.net/user/farawayplace613下載(不需要資源分的)該實例的代碼。Encode.dll在Debug的文件夾內。
代碼如下:

//Form1.Designer.cs
namespace TestEnCode
{
partial class Form1
{
/// <summary>
/// 必需的設計器變量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的資源。
/// </summary>
/// <param name="disposing">如果應釋放托管資源,為 true;否則為 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows 窗體設計器生成的代碼
/// <summary>
/// 設計器支持所需的方法 - 不要
/// 使用代碼編輯器修改此方法的內容。
/// </summary>
private void InitializeComponent()
{
this.txtSource = new System.Windows.Forms.TextBox();
this.txtResult = new System.Windows.Forms.TextBox();
this.button1 = new System.Windows.Forms.Button();
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// txtSource
//
this.txtSource.Location = new System.Drawing.Point(75, 26);
this.txtSource.Name = "txtSource";
this.txtSource.Size = new System.Drawing.Size(100, 22);
this.txtSource.TabIndex = 0;
//
// txtResult
//
this.txtResult.Location = new System.Drawing.Point(75, 126);
this.txtResult.Name = "txtResult";
this.txtResult.Size = new System.Drawing.Size(100, 22);
this.txtResult.TabIndex = 1;
//
// button1
//
this.button1.Location = new System.Drawing.Point(75, 78);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 23);
this.button1.TabIndex = 2;
this.button1.Text = "簡繁轉換";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(23, 29);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(41, 12);
this.label1.TabIndex = 3;
this.label1.Text = "轉換源";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(12, 136);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(53, 12);
this.label2.TabIndex = 4;
this.label2.Text = "轉換結果";
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(320, 277);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
this.Controls.Add(this.button1);
this.Controls.Add(this.txtResult);
this.Controls.Add(this.txtSource);
this.Name = "Form1";
this.Text = "簡繁體轉換測試";
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.TextBox txtSource;
private System.Windows.Forms.TextBox txtResult;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
}
}

注意了,上面下載地下載的是VS2008創建的項目.
可能需要你把代碼拷貝到你自己的環境中。下載中重要的是Encode.dll。
哈哈,簡單吧,就兩句就搞定了簡繁體的轉換。
作者:程呈
原文來自:http://blog.csdn.net/farawayplace613/archive/2008/09/10/2910527.aspx

聲明:本網頁內容旨在傳播知識,若有侵權等問題請及時與本網聯系,我們將在第一時間刪除處理。TEL:177 7030 7066 E-MAIL:11247931@qq.com

文檔

asp.net中簡體轉繁體實現代碼

asp.net中簡體轉繁體實現代碼:我還是直接貼例子在說明一下吧: 代碼如下://Form1.cs using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text;
推薦度:
標簽: 轉換 繁體 代碼
  • 熱門焦點

最新推薦

猜你喜歡

熱門推薦

專題
Top
主站蜘蛛池模板: 欧美日韩精品免费一区二区三区 | 亚洲va欧美va天堂v国产综合 | 国产精品亚洲综合一区 | 国产一区在线观看视频 | 亚洲欧洲日韩国产 | 国产精品一区欧美日韩制服 | 国产精品久久久久久一区二区三区 | 国产不卡在线 | 欧美日韩精品在线播放 | 亚洲国产精品免费视频 | 五十路在线播放 | 欧美一区精品二区三区 | 久久久91精品国产一区二区 | 91精品国产亚一区二区三区 | 欧美αv日韩αv另类综合 | 一区在线播放 | 91久久国产综合精品 | 欧美极品欧美精品欧美视频 | 日本成人一区二区 | 亚洲 另类 在线 欧美 制服 | 午夜三级视频 | 国产一级在线观看 | 91色欧美 | 欧美日韩一区二区三区久久 | 欧美a在线视频 | 最新国产在线播放 | 欧美激情国产日韩精品一区18 | 二区视频 | 欧美综合国产精品日韩一 | 图片亚洲va欧美va国产综合 | 热综合一本伊人久久精品 | 国产精品久久久久9999 | 国产成人精品日本亚洲11 | 国产精品第十页 | 欧美亚洲另类在线观看 | 伊人一级 | 波多野结衣在线免费观看 | 午夜精品一区二区三区在线观看 | 激情另类国内一区二区视频 | 国产黄色片在线观看 | 国产中文在线 |