data caching

  • Thread starter Thread starter m.posseth
  • Start date Start date
M

m.posseth

Hello ,,,

I have a nice one :-)


with

store data
System.AppDomain.CurrentDomain.SetData("mystuff", myType)

getdata

myType =(myType) System.AppDomain.CurrentDomain.GetData("mystuff")

i can simulate a simular caching mechanisme as in asp.net

however does someone know how i can remove something from the cache ?
 
Dim myType As String = "My Stuff"

'set reference to something

System.AppDomain.CurrentDomain.SetData("mystuff", myType)

MsgBox(System.AppDomain.CurrentDomain.GetData("mystuff"))

'Set reference to nothing

System.AppDomain.CurrentDomain.SetData("mystuff", Nothing)

MsgBox(System.AppDomain.CurrentDomain.GetData("mystuff"))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top