ASP.NET中Server物件的方法

iDotNetSpace發表於2008-09-12

本文給大家簡單介紹一下 ASP.NET 中的 Server 物件的方法,初學者可以當個參照表來用。
  urIEncode 將URL字串編碼,語法格式為:

以下是引用片段:
  UrlEncode(ByVal String As String)As String


  urIDecode 將編碼後的URL字串解碼,語法格式為:

以下是引用片段:
  UrlDecode(ByVal String As String)As String


  MaDPath 取得檔案的實際路徑,語法格式為:

以下是引用片段:
  MapPath(ByVal path As String)As String


  HtmlEncode 將字串編碼為HTML資料,語法格式為:

以下是引用片段:
  HtmlEncode(ByVal String As String)As String


  HtmlDecode 將HTML編碼後的資料解碼還原為HTML,語法格式為:

以下是引用片段:
  HtmlDecode(ByVal String As String)As String


  CreateObjectStatic 用ProglD建立COM元件,語法格式為:

以下是引用片段:
  CreateObjectStatic(ByVal ProglD As String)As Object


  CreateObjectFromClsid 用CLSID建立COM元件,語法格式為:

以下是引用片段:
  CreateObjectFromClsid(ByVal Clsld As String)As Object


  CreateObject 建立COM元件,語法格式為:

以下是引用片段:
  CreateObiect(BVVal Pro~ID As String)AS 0biect


 

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/12639172/viewspace-446874/,如需轉載,請註明出處,否則將追究法律責任。

相關文章