Time of Update: 2018-12-05
讀取網頁Reponse資料,下面是一個浪馳簡訊的執行個體 public static string HttpSMSPost(HttpWebRequest hr, string url, string parameters) { string strRet = null; ASCIIEncoding encoding = new ASCIIEncoding(); byte[] data =
Time of Update: 2018-12-05
項目中要求得到用戶端的MAC地址及IP地址,但找了網上很多的例子,但經測試過之後得到的都是伺服器的代碼,後來看到一篇文章中說到,因為這網頁上啟動並執行伺服器端的代碼,所以無法得到用戶端的的MAC地址。下面是查到的一些資料,但是都是得到用戶端的代碼,下面是一些網上找到這些代碼的集錦: Label1.Text = "//用戶端ip:" +
Time of Update: 2018-12-05
一、索引的概念索引就是加快檢索表中資料的方法。資料庫的索引類似於書籍的索引。在書籍中,索引允許使用者不必翻閱完整個書就能迅速地找到所需要的資訊。在資料庫中,索引也允許資料庫程式迅速地找到表中的資料,而不必掃描整個資料庫。二、索引的特點1.索引可以加快資料庫的檢索速度2.索引降低了資料庫插入、修改、刪除等維護任務的速度3.索引建立在表上,不能建立在視圖上4.索引既可以直接建立,也可以間接建立5.可以在最佳化隱藏中,使用索引6.使用查詢處理器執行SQL語句,在一個表上,一次只能使用一個索引7.其他
Time of Update: 2018-12-05
在網上也沒有認真找一下其API及操作說明文檔,到時看到再Mark一下,下面是一個產生Doc的執行個體代碼 DocumentBuilder builder = new DocumentBuilder(); builder.ParagraphFormat.Alignment = ParagraphAlignment.Left; builder.Writeln("helloword");//標題
Time of Update: 2018-12-05
Infopath Web Service 帶參數查詢WebService.cs其中一個方法為GetCalculate,下面是其具體的代碼 [WebMethod] public CalculateInfo GetCalulate(DateTime dtBegin,string sBegin,DateTime dtEnd,string sEnd) { CalculateInfo oCalculate = new CalculateInfo(); if
Time of Update: 2018-12-05
TextBox 是允許多行的 <asp:TextBox ID="txtEmployeeID" TextMode="MultiLine" Rows="8" runat="server"></asp:TextBox> 由於查詢的時候,需要把TextBox多行的給分屯出來進行查詢,分離方法如下,根據\r來分離 string[] strArr1 = txtEmployeeID.Text.Split('\r');
Time of Update: 2018-12-05
下面是根據XPath教程的一次查詢嘗試! <script type="text/javascript"> function loadXMLDoc(fileName) { if (window.XMLHttpRequest) { xhttp = new XMLHttpRequest(); } else { //IE5
Time of Update: 2018-12-05
用item.Delete 來刪除 ,如果行數在10多行的時候,刪除所需要的時間會達到好幾1-2秒,所以非常之慢!一般來說,當行數多的時候會採取以下的方法來刪除public void DeleteData(SPListItemCollection items, SPList itemlist) { SPSecurity.RunWithElevatedPrivileges(delegate() { using (
Time of Update: 2018-12-05
ALTER FUNCTION [dbo].[SumString] ( @userId nvarchar(40), @selectName nvarchar(4000)) RETURNS nvarchar(4000) AS BEGIN declare @Str nvarchar(4000) declare @ProductName nvarchar(4000) set @Str =''declare pcurr cursor for select '"'+@selectName+'"
Time of Update: 2018-12-05
<script language="javascript" type="text/javascript"> function iframeAutoFit(iframeObj) { setTimeout(function () { if (!iframeObj) return; iframeObj.height = (iframeObj.Document ?
Time of Update: 2018-12-05
using CodeArt.SharePoint.CamlQuery;string camlstring= CamlBuilder.Where(sourcelist, new QueryField("SwfID", false).IsNull || new QueryField("SwfID", false).Equal(string.Empty));SPQuery query = new SPQuery();query.Query =
Time of Update: 2018-12-05
代碼如下: #region GridView1 Setting this.GridView1.PageIndexChanging += new GridViewPageEventHandler(GridView1_PageIndexChanging); this.GridView1.Sorting += new GridViewSortEventHandler(GridView1_Sorting); this.GridView1.RowCreated
Time of Update: 2018-12-05
基礎就不說了,下面是直接貼原始碼 (function ($) { $.extend($, { fixedWidth: function (str, length, char) { str = str.toString(); if (!char) { char = "..."; } var num = length -
Time of Update: 2018-12-05
block元素的特點是:總是在新行上開始;高度,行高以及頂和底邊距都可控制;寬度預設是它的容器的100%,除非設定一個寬度<div>, <p>, <h1>, <form>, <ul>和<li>是塊元素的例子。inline元素的特點是: 和其他元素都在一行上;高,行高及頂和底邊距不可改變;寬度就是它的文字或圖片的寬度,不可改變。<span>, <a>, <label>,
Time of Update: 2018-12-05
private bool AddUserIntoGroup(SPWeb web, string sGroupName, int iUserID) { bool res = false; try { web.AllowUnsafeUpdates = true; SPGroup oGroup = web.SiteGroups[sGroupName]; SPUser oUser =
Time of Update: 2018-12-05
在InfoPath裡快顯視窗,可以用Notify(message)就可以實現,不過要修改layouts檔案夾裡面一個FormServer檔案修改後的代碼為 <%@ Page inherits="Microsoft.Office.InfoPath.Server.Controls.FormServerPage,Microsoft.Office.InfoPath.Server, Version=12.0.0.0, Culture=neutral,
Time of Update: 2018-12-05
BEGIN…END其文法如下:BEGIN<命令列或程式塊>ENDBEGIN…END用來設定一個程式塊,將在BEGIN…END內的所有程式視為一個單元執行BEGIN…END經常在條件陳述式,如IF…ELSE中使用。在BEGIN…END中可嵌套另外的BEGIN…END來定義另一程式塊。 IF…ELSE其文法如下:IF <條件運算式><命令列或程式塊>[ELSE
Time of Update: 2018-12-05
XML代碼如下:<?xml version="1.0" encoding="utf-8"?><Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <Module Name="_catalogs" Url="_catalogs/masterpage"> <File Path="SimpleDefaultMaterModule\simple-fdn.master"
Time of Update: 2018-12-05
SharePoint的EventHandler主要有Web Level,List Level,List Item Level,Email幾種。SharePoint的event handler主要是繼承SPWebEventReceiver, SPEmailEventReceiver, SPListEventReceiver和SPItemEventReceiver類去實現其中相應的方法來完成我們的需求。ModifiedPermissions:using System;using
Time of Update: 2018-12-05
public static string strLDAP = "LDAP://Test.com"; public static void GetADMails(ref List<string> list, string strLoginName) { DirectoryEntry newEntry = new DirectoryEntry(strLDAP); strLoginName =