Method ya ASP Contents.Remove

Mwongozo wa Object ya Application

Method ya Contents.Remove inasifungua kipengele kwenye kundi cha Contents.

Mada

Application.Contents.Remove(name|index)
Session.Contents.Remove(name|index)
Makosa Maelezo
name Jina la kipengele cha kufaika.
index Namba ya kufungua ya kipengele cha kufaika.

Kufaa kwa kifaa cha Application

Mfano 1

<%
Application("test1")=("First test")
Application("test2")=("Second test")
Application("test3")=("Third test")
Application.Contents.Remove("test2")
kwa kila x katika Application.Contents
 Response.Write(x & "=" & Application.Contents(x) & "<br />")
next
%>

Muonekano:

test1=First test
test3=Third test

Mfano 2

<%
Application("test1")=("First test")
Application("test2")=("Second test")
Application("test3")=("Third test")
Application.Contents.Remove(2)
kwa kila x katika Application.Contents
 Response.Write(x & "=" & Application.Contents(x) & "<br />")
next
%>

Muonekano:

test1=First test
test3=Third test

Kufaa kwa kifaa cha Session:

Mfano 1

<%
Session("test1")=("First test")
Session("test2")=("Second test")
Session("test3")=("Third test")
Session.Contents.Remove("test2")
for each x in Session.Contents
 Response.Write(x & "=" & Session.Contents(x) & "<br />")
next
%>

Muonekano:

test1=First test
test3=Third test

Mfano 2

<%
Session("test1")=("First test")
Session("test2")=("Second test")
Session("test3")=("Third test")
Session.Contents.Remove(2)
for each x in Session.Contents
 Response.Write(x & "=" & Session.Contents(x) & "<br />")
next
%>

Muonekano:

test1=First test
test3=Third test

Mwongozo wa Object ya Application