HOME > ASP > ASP Object > ASP Application.Contents() - Application Object
ASP Application.Contents() - Application Object
Application.Contents() เป็น Collections ที่ใช้เก็บตัวแปรที่มี Key และ Value
Syntax
<%
Application.Contents(Key)
%>
ASPApplicationObject.asp
<% Option Explicit %>
<html>
<head>
<title>ThaiCreate.Com ASP Application Object</title>
</head>
<body>
<%
Application("SiteName") = "www.ThaiCreate.Com"
Application("Version") = "2008"
Application("Creator") = "Mr.Weerachai Nukitram"
Dim List
For Each List In Application.Contents
Response.write(List &" = " & Application.Contents(List) & "<br>")
Next
Response.write("<hr>")
For List = 1 To Application.Contents.Count
Response.write(Application.Contents.Key(List) &" = " & Application.Contents(List) & "<br>")
Next
%>
</body>
</html>