天天看點

我對FreeTextBox簡單使用

對于FreeTextBox(版本3.1.6)在ASP.Net 2.0中使用,

放上下載下傳位址:

 下載下傳最新版FreeTextBox(版本3.1.6),解壓

   FreeTextBox 3.1.6 (2006/07/18)

   部落格園本地下載下傳: https://files.cnblogs.com/cleo/FTBv3-1-6.zip

   作者網站下載下傳位址:http://freetextbox.com/download/

   詳細版本有哪些改進和修改曆史可以看這裡:http://freetextbox.com/download/changelog.aspx

隻需要将:FreeTextBox.DLL   ftb.imagegallery.aspx  和aspnet_client檔案夾 拷入你的項目當中

打開ASP.Net2.0項目,添加引用。(如果添加過以前版本的FreeTextBox,先删除以前版本的引用)

将FreeTextBox添加到工具欄。(工具欄〉正常〉選擇項〉浏覽到DLL檔案,添加)

<FTB:FreeTextBox ID="Free1"   ImageGalleryPath="~/Images"         
Language="zh-CN" runat="server"        
ButtonDownImage="True"      
toolbarlayout="ParagraphMenu,      
FontFacesMenu,      
FontSizesMenu,FontForeColorsMenu,      
FontForeColorPicker,FontBackColorsMenu,      
FontBackColorPicker|Bold,Italic,      
Underline,Strikethrough,Superscript,      
Subscript,RemoveFormat|JustifyLeft,JustifyRight,      
JustifyCenter,JustifyFull;BulletedList,      
NumberedList,Indent,Outdent;CreateLink,Unlink,      
InsertImage|Cut,Copy,Paste,Delete;      
Undo,Redo,Print,Save|SymbolsMenu,StylesMenu,      
InsertHtmlMenu|InsertRule,InsertDate,      
InsertTime|InsertTable,EditTable;InsertTableRowAfter,      
InsertTableRowBefore,DeleteTableRow;      
InsertTableColumnAfter,      
InsertTableColumnBefore,DeleteTableColumn|InsertForm,      
InsertTextBox,InsertTextArea,      
InsertRadioButton,      
InsertCheckBox,InsertDropDownList,InsertButton|InsertDiv,      
EditStyle,InsertImageFromGallery,Preview,SelectAll,      
WordClean,NetSpell"      
runat="Server">     </FTB:FreeTextBox>      

上面代碼中 将FreeTextBox中的功能按鈕全部顯示出來 并使語言為中文 設定上傳圖檔的儲存位址

ftb.imageegallery.aspx 中 設定屬性

<FTB:ImageGallery id="ImageGallery1"      
SupportFolder="~/aspnet_client/FreeTextBox/"      
AllowImageDelete="true" AllowImageUpload="true"       
AllowDirectoryCreate="true" AllowDirectoryDelete="true" runat="Server"/>      

是否允許删除圖檔 上傳圖檔 是否允許建立檔案夾 删除檔案夾

在freetextbox 中 使用了 Imageegallery 上傳圖檔  但是 在界面中是英文的

在網上說使用  ildasm.exe  來 轉存

ildasm.exe 位于 X:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin 下

将 Freetextbox.dll  使用ildasm 轉存後  反編譯出很多個小圖檔 和幾個JS 檔案

我們更改下 FreeTextBoxControls.Resources.JavaScript.FTB-Pro.js 中相應的 英文句子 來漢化它

當更改完成後 我們再使用 ilasm.exe 來再進行拼裝DLL 檔案

ilasm.exe檔案位于 C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 中

MSIL 彙程式設計式 (Ilasm.exe)

ilasm myTestFile /dll       

下面的指令對 MSIL 檔案 myTestFile.il 進行彙編并産生 .dll 檔案 myNewTestFile.dll。

NET Framework 工具 

MSIL 彙程式設計式 (Ilasm.exe) 

MSIL 彙程式設計式從 Microsoft 中間語言 (MSIL) 生成可移植可執行的 (PE) 檔案。(有關 MSIL 的更多資訊,請參見編譯為 MSIL。)可以運作結果可執行檔案(該檔案包含 MSIL 和所需的中繼資料)以确定 MSIL 是否按預期執行。

參考

FreeTextBox 3.14版改進與漢化

我對FreeTextBox簡單使用
我對FreeTextBox簡單使用