Alvin Bruney [ASP.NET MVP]
4/6/2009 2:01:00 AM
I don't see how that is possible; these are two different engines. Build a
webservice or expose your cache via a public method. That should work.
Essentially, a function that returns context.current. current is not
guaranteed to be valid so this is the only gotcha.
--
Regards,
Alvin Bruney
Auther Plug
OWC Blackbook now on download at www.lulu.com/owc
"Paul Hale" <PaulHale@newsgroups.nospam> wrote in message
news:AF9B622E-304D-4353-9074-3C4DFA4366F4@microsoft.com...
> I have a workflow that runs within a web application (My workflows DLL is
> copied to my web apps BIN folder). My web application has a number of
> items
> cached. I would like to access these cached items from within my
> workflow.
>
> I would of thought that as the Workflows dll runs within my web app it
> would
> run in the same context and I should be able to access it. However this
> line
> of code returns "Object ref not set to an instance of an object)...
>
> int myCacheCount
> myCacheCount= System.Web.HttpContext.Current.Cache.Count;
>
> Does anybody know if you can access asp.net cache from within a WWF
> workflow
> and if so how?
>
> Paul.
>
>
>
>