Click here to Skip to main content
15,886,963 members
Home / Discussions / C#
   

C#

 
GeneralClient / Server Pin
Bonsai200429-Apr-04 6:20
Bonsai200429-Apr-04 6:20 
GeneralRe: Client / Server Pin
Heath Stewart29-Apr-04 6:46
protectorHeath Stewart29-Apr-04 6:46 
GeneralRe: Client / Server Pin
Andy Brummer29-Apr-04 6:46
sitebuilderAndy Brummer29-Apr-04 6:46 
GeneralRe: Client / Server Pin
Dave Kreskowiak29-Apr-04 8:45
mveDave Kreskowiak29-Apr-04 8:45 
GeneralRe: Multi-threading in a web service Pin
mjmcinto29-Apr-04 6:16
mjmcinto29-Apr-04 6:16 
GeneralRe: Multi-threading in a web service Pin
Andy Brummer29-Apr-04 6:39
sitebuilderAndy Brummer29-Apr-04 6:39 
GeneralRe: Multi-threading in a web service Pin
Heath Stewart29-Apr-04 6:49
protectorHeath Stewart29-Apr-04 6:49 
GeneralRe: Multi-threading in a web service Pin
mjmcinto29-Apr-04 12:44
mjmcinto29-Apr-04 12:44 
Yes that was me, and thank you for your help. I've got the call back working to where it will remove the cached data on a change. However, in the method that does that, I also try to reload and then re-add the data, but it doesn't re-add.

Here is the method:

<br />
public void TPMDataRemovedCallback(String k, Object v, CacheItemRemovedReason r){<br />
 TPMreason = r;<br />
 string tpmDataKey = "TPMDATA";<br />
 if(onTPMDataRemove == null)<br />
   onTPMDataRemove = new CacheItemRemovedCallback (this.TPMDataRemovedCallback);<br />
 DateTime NoAbsoluteExpiration = Cache.NoAbsoluteExpiration;<br />
 TimeSpan NoSlidingExpiration = Cache.NoSlidingExpiration;<br />
 CacheItemPriority Priority = CacheItemPriority.AboveNormal;<br />
 Context.Cache.Remove(tpmDataKey);<br />
 System.IO.FileInfo fileInfo = new System.IO.FileInfo(tpmFileName);<br />
 tpmData = tpm.LoadTPM();<br />
 try{<br />
   Context.Cache.Add(tpmDataKey,this.tpmData,this.tpmDataCacheDependency,NoAbsoluteExpiration,NoSlidingExpiration,Priority,onTPMDataRemove);<br />
 }<br />
 catch(System.Exception caught){<br />
   Console.WriteLine("Exception == " + caught);<br />
 }<br />
}<br />

I don't see an exception get caught, but the cache at Context.Cache[tpmDataKey] doesn't contain anything. What am I doing wrong?
GeneralRe: Multi-threading in a web service Pin
Heath Stewart29-Apr-04 14:24
protectorHeath Stewart29-Apr-04 14:24 
GeneralRe: Multi-threading in a web service Pin
mjmcinto30-Apr-04 2:45
mjmcinto30-Apr-04 2:45 
GeneralRe: Multi-threading in a web service Pin
Heath Stewart30-Apr-04 3:14
protectorHeath Stewart30-Apr-04 3:14 
Generalprinting multiple pages Pin
nmah29-Apr-04 5:07
nmah29-Apr-04 5:07 
GeneralRe: printing multiple pages Pin
Heath Stewart29-Apr-04 5:37
protectorHeath Stewart29-Apr-04 5:37 
GeneralRe: printing multiple pages Pin
nmah29-Apr-04 7:26
nmah29-Apr-04 7:26 
GeneralRe: printing multiple pages Pin
Heath Stewart29-Apr-04 8:28
protectorHeath Stewart29-Apr-04 8:28 
GeneralRe: printing multiple pages Pin
nmah29-Apr-04 8:32
nmah29-Apr-04 8:32 
GeneralRe: printing multiple pages Pin
..Hubert..29-Apr-04 5:42
..Hubert..29-Apr-04 5:42 
GeneralScrewed up a service. Pin
Xian29-Apr-04 4:58
Xian29-Apr-04 4:58 
GeneralRe: Screwed up a service. Pin
Heath Stewart29-Apr-04 5:24
protectorHeath Stewart29-Apr-04 5:24 
GeneralRe: Screwed up a service. Pin
Xian29-Apr-04 5:47
Xian29-Apr-04 5:47 
QuestionHow to Make a MDI form itself XP theme aware Pin
TaoLi29-Apr-04 3:54
TaoLi29-Apr-04 3:54 
AnswerRe: How to Make a MDI form itself XP theme aware Pin
Heath Stewart29-Apr-04 4:25
protectorHeath Stewart29-Apr-04 4:25 
AnswerRe: How to Make a MDI form itself XP theme aware Pin
Heath Stewart29-Apr-04 4:27
protectorHeath Stewart29-Apr-04 4:27 
GeneralRe: How to Make a MDI form itself XP theme aware Pin
TaoLi29-Apr-04 4:37
TaoLi29-Apr-04 4:37 
GeneralRe: How to Make a MDI form itself XP theme aware Pin
Jon G29-Apr-04 5:24
Jon G29-Apr-04 5:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.