0

Bear with a bit me before jumping straight to the normal caching fix solutions. Here's what happening:

I have a project, a single project out of dozens in our solution that appears to be refusing to update its code when I build and run. It's not part of the xap, but a dll sitting along side the xap.

Things I've already determined not a solution:

  • I've checked the output of its dll and it has been built, and its contents updated to match my code, verified with dotPeek. But it refuses to display the updated code.
  • I clean, rebuild the solution, and restart the dev server but it refuses to display the updated code.
  • I switch to a different browser, no dice.
  • I clear browser cache's to no avail.
  • I completely delete my local code and do a fresh fetch from our repository, again, no love from silverlight.

I have not been without a little success though. The ONE bone I've been thrown was over the weekend. Not touching it for a couple days, I came back to work on Monday and, without having done anything to it, it just updated. Now, however, it's cached again, or something, because it's stuck in the last set of changes I made to it.

So my question is this: What am I missing?

Wes P
  • 9,622
  • 14
  • 41
  • 48
  • When you say you checked the output dll, did you check the ClientBin folder in the web app project? – Eren Ersönmez Jan 10 '12 at 16:35
  • "It's not part of the xap, but a dll sitting along side the xap"? Please eloborate? – AnthonyWJones Jan 10 '12 at 17:11
  • "So my question is this: What am I missing?" - Answer: An internal caching mechanism that our application uses. So, none of you could really have helped me as it was an architectural "feature" I was unaware of. – Wes P Jan 10 '12 at 19:29

3 Answers3

0

Here there are couple answers: Prevent Silverlight 3 from caching while debugging
Code below helped me(add this to Page_Load of page that hosted the app ):

Response.Cache.SetExpires(DateTime.Now.AddSeconds(-100));
Response.Cache.SetCacheability(HttpCacheability.NoCache);

UPDATE: Prevent Silverlight xap from being cached by proxy server

Community
  • 1
  • 1
Anatolii Gabuza
  • 6,184
  • 2
  • 36
  • 54
0

Most likely your files may be read only and MS Build fails to display error message and it does not update files. In case if you have mistakenly checked in your .xap files, then this is possible, you will have to remove it from your source control and also make .xap file writable by removing readonly checkbox.

Visual Studio checks in your .xap files by mistake and silverlight build does not report any error.

Second, do you have any other file backup service installed like Shadow copy or Dropbox kind of online backup service, something is probably making xap files readonly and that is causing this problem.

Akash Kava
  • 39,066
  • 20
  • 121
  • 167
0
"So my question is this: What am I missing?"

An internal caching mechanism that our application uses. So, none of you could really have helped me as it was an architectural feature of our software.

Wes P
  • 9,622
  • 14
  • 41
  • 48