asp获取数据库的连接属性的方法

2015-08-12 15:59:42来源:作者:人点击

   asp获取数据库的连接属性的方法

  Option Explicit

  dim objCNN

  dim intCTProps

  dim item

  dim vbCRLF

  vbCRLF = chr(10)

  Response.Write "" & vbCRLF

  Response.Write "

  春风精彩之查看数据库属性" & vbCRLF

  Response.Write vbCRLF

  set objCNN = Server.CreateObject("ADODB.connection")

  objCNN.Open "DSN=VicTest"

  Response.Write ">编号" & vbCRLF

  Response.Write ">Name>值" & vbCRLF

  intCTProps = 0

  for each item in objCNN.Properties

  intCTProps = intCTProps + 1

  Response.Write "" & intCTProps & "" & vbCRLF

  Response.Write "" & item.name & "" & vbCRLF

  Response.Write "" & item.value & "" & vbCRLF

  next

  Response.Write "" & vbCRLF

  Response.Write vbCRLF

  Response.Write "" & vbCRLF

  set objCNN = Nothing

  set intCTProps = nothing

  set item = nothing

  set vbCRLF = nothing

  %>

最新文章

123

最新摄影

微信扫一扫

第七城市微信公众平台