Time of Update: 2018-12-06
Asp.net Socket用戶端(遠程發送和接收資料) 收藏 /*************************************** * 對象名稱: SocketObj * 功能說明: 遠程發送與接收 * 試用樣本: * using EC; //引用空間名 * string url = "218.75.111.74"; // URL也可以是(http://www.baidu.com/)這種形式 * int port = 8000; //連接埠 * string SendStr = "
Time of Update: 2018-12-06
先看看ASP.NET頁面重新整理的實現方法: 第一: private void Button1_Click( object sender, System.EventArgs e ) {Response.Redirect( Request.Url.ToString( ) ); } 第二: private void Button2_Click( object sender, System.EventArgs e ) { Response.Write( " < script
Time of Update: 2018-12-06
唯一一本涵蓋了asp.net所有測試方面的專業書籍基本資料原書名: Testing ASP.NET Web Applications原出版社: Wrox作者: (美)Jeff McWherter Ben Hall [作譯者介紹]譯者: 錢峰 張少華 丁峰出版社:清華大學出版社ISBN:9787302247845上架時間:2011-3-22出版日期:2011
Time of Update: 2018-12-06
微軟技術大師力作,國內多位MVP聯袂翻譯涵蓋ASP.NET 4 所有新特性程式碼範例豐富,提供C#和VB.NET兩種版本《ASP.NET 4揭秘.第1卷》基本資料原書名: ASP.NET 4 Unleashed原出版社: Sams作者: (美)Stephen Walther Kevin Hoffman Nate
Time of Update: 2018-12-06
asp在 操作 sql server 的update時 返回 更新條目數可以在 connection的execute方法中放入一個參量,調用方法如 conn.execute(sql,i),這個i就記錄了更新的條目數,範例程式碼:Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->connSQLServerStr = "Provider=SQLOLEDB.
Time of Update: 2018-12-06
ASP 中也可以用Regex,為了方便使用,對Regex操作進行了封裝,目前只封裝了兩個:1、正則替換Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->'功能:通過Regex替換字串'參數: str 原字串 ' patton 正則匹配運算式' restr 替換字串' op 選項
Time of Update: 2018-12-06
最近好忙,連續加班好幾周了。雖然辛苦,但卻頗有收穫,最大的收穫是新項目用了ASP.NET MVC。要說的是ASP.Net Mvc 還真好。等項目忙好了,我計劃針對項目中學到的技術點做個總結,寫一些小例子以便日後可以用。 ASP.Net MVC 給我最大的印象是清晰,在寫代碼時不再有傳統ASP.net
Time of Update: 2018-12-06
.Net 網站項目引用類庫時,有時在類庫裡需要調用檔案如xml,此時時檔案路徑比較難找到,研究了一下,暫時得出以下的解決方案。 首先目錄安排如下solution |--project | |--xml | | |--test.xml | |--Class1.cs |--web |--Default.aspx 現在web 引用
Time of Update: 2018-12-06
同事寫的,收錄一下,方法如下: /// <summary> /// 防止重複提交 /// </summary> /// <param name="imaButtons">按鍵集合</param> /// <param name="clientID">頁面有JS驗證的組件</param> public void RepeatSubmitCheckForRC(
Time of Update: 2018-12-06
因為工作需要,和自己MVC的技術不夠純熟,尤其是JS方面.所有又轉回了webfrom開發(其實各有各的好處).很簡單的一個功能,就是為Button控制項添加一個確認提示框,以前記得都是在後台加:btnXXX.Attributes.Add("onclick","if (!confirm(是否確定刪除?')) {return false;}");但是非常奇怪,我加了沒反應.後來發現個更簡單的方法: <asp:Button ID="Button1" runat="server" Text="
Time of Update: 2018-12-06
一直想搞明白大檔案的上傳是怎麼實現的,還有怎麼實現進度條顯示。今天總算在部落格園首頁看到一篇相關的文章。原文地址:asp.net大檔案分塊上傳與進度顯示,完整項目源碼下載了代碼用vs開啟後,裡面的檔案結構:但是工程編譯的時候,出現了問題。就去作者提供的資料找了找,發現了一個學習這方面的一個好地方:http://www.cnblogs.com/stg609/裡面關於大檔案上傳有詳細的介紹,稍稍看了下關於tcp的介紹和asp.net的運行情況,其實之前看過幾次了,權當複習。不過感覺實現大檔案上傳還是
Time of Update: 2018-12-06
1.新的文法,在aspx中設定<%$ ConnectionStrings : NorthwindConnectionString
Time of Update: 2018-12-06
1.控制項的設定焦點可以設定焦點的控制項如下:Button,CheckBox,DropDownList,HyperLink,ImageButton,LinkButton,ListBox,RadioButton,TextBox四種方法,殊途同歸:Page.SetFocus(txtUserID);this.SetFocus(txtUserID);Page.SetFocus(txtUserID.ClientID);txtUserID.Focus();——設定焦點是頁面(Page)級的,自動產生JS:W
Time of Update: 2018-12-06
HtmlHead類動態添加<head>中子標籤,如<title>和<style>,尤其是後者,就是動態配置CSS。例子如下: protected void Page_Load(object sender, EventArgs e) { Style bodyStyle = new Style(); bodyStyle.ForeColor = System.Drawing.Color.Red; bodyStyl
Time of Update: 2018-12-06
在ASP.NET 2.0使用以下四種方式:HyperLinkResponse.Redirect()Server.Transfer()Cross-Page Posting以下只說第四種,即“跨網頁公布”區別於PostBack(只是自己ReCall自己),不再需要URL中的參數QueryString方法1:使用PreviousPage.FindControl訪問來源網頁A的空間屬性屬性。A頁面有TextBoxA,在A頁面的Button上設制PostBackUrl屬性,為B頁面。在B載入頁面時:
Time of Update: 2018-12-06
CodeCode highlighting produced by Actipro CodeHighlighter
Time of Update: 2018-12-06
在asp.net調試javascript代碼主要有以下方法:一、在要調試的javascript代碼前加入debugger,相當於下斷點 注意,這種方式需要在IE的Internet選項中,禁用指令碼調試(Internet
Time of Update: 2018-12-06
FreeTextBox 是一個基於 Internet Explorer 中 MSHTML 技術的 ASP.NET 開原始伺服器控制項。這是一款優秀的自由軟體(Free Software),我們可以輕鬆地將其嵌入到 Web Forms 中實現 HTML 內容的線上編輯,在新聞發布、部落格寫作、論壇社區等多種 Web 系統。http://files.cnblogs.com/soman/FreetextBox.zip(點擊下載控制項) 建立一個ASP項目 位置要選擇 HTTPOK後 在工具列中
Time of Update: 2018-12-06
以下是引用片段: using System; using System.Collections.Generic; using System.Text; using System.Data; using System.Data.SqlClient; namespace OTC.Utility ...{ public sealed class JSONHelper ...{ /**//// /// 擷取JSON字串 /// /// 值 ///
Time of Update: 2018-12-06
using System;using System.Data;using System.Configuration;using System.Collections;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using