2,添加引用Microsoft Active Server Pages Object Library
Public objContext As objectContext
Public Application As ASPTypeLibrary.Application
Public Server As ASPTypeLibrary.Server
Public Session As ASPTypeLibrary.Session
Public Response As ASPTypeLibrary.Response
Public Request As ASPTypeLibrary.Request
On Error Resume Next
Set Application = Nothing
Set Server = Nothing
Set Session = Nothing
Set Request = Nothing
Set Response = Nothing
Set objContext = Nothing
End Sub
Response.Write "王永勝的動態鏈接庫"
End Sub
控制面板-管理工具-組件服務-com+應用程序
新建-應用程序-空應用程序
註冊上面的dll
dim obj
set obj=server.CreateObject("project1.Class1")
obj.Print1