views:

11

answers:

1

Is there any way of identifying (at run time) if my application is running in partial-trust mode or not? I'm considering deploying two versions of my ClickOnce application - one full trust and the other partial trust and there are some things I want to do differently depending on the deployment mode (such as caching downloaded images on full-trust)

I've already looked into using Isolated Storage, but apparently you're limited to 10K for storage: not good for image caching!

+1  A: 

We create a folder in the LocalApplicationData with our company name and store cached files and information there. This is where Microsoft recommended you put data when Vista came out, because you could no longer write it to Program Files as so many developers did.

Here's an article about it (we use it for data too): Where do I put my data to keep it safe from ClickOnce updates?

You can store information in LocalApplicationData regardless of whether the application is full trust or partial trust.

RobinDotNet
One of the differences between isolated storage and LocalApplicationData(LAD) is that LAD is designed for application-wide data whereas isolated storage exists on a _per assembly_ basis.
Greg D