Print Page | Close Window

Caching doesn't work

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce 2010
Forum Discription: For .NET 4.0
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=2968
Printed Date: 28-Mar-2024 at 9:09am


Topic: Caching doesn't work
Posted By: Testing
Subject: Caching doesn't work
Date Posted: 21-Sep-2011 at 5:54am
Hello,

I'm building my first application with IdeaBlade DevForce.
The goal is to test purposes.

But I'm having a little problem with the caching stuff..
I'm creating an WinForms Application.
This loads a form with all the data on load.

I've added a "Refresh" button which load's the same data again.
So, when I press refresh, it just needs to check the cache and show the form again.

But it doesn't..
I followed the silverlight tutorial, and added a Messagebox when Fetching.
It fetches the data the first and second time.

The cache has data.. The EntityManager.CacheStateManager shows that there are 200 rows.

How can i use the cache and work the second time disconnected?

BTW: I've tried it with every DefaultQueryStategy there is, which performs an error if I select DataSourceThenCache (I think it must be Normal in my case)


Thank you in advance



Replies:
Posted By: sbelini
Date Posted: 26-Sep-2011 at 11:11am
Hi Testing,

You should be able to use QueryStrategy.CacheOnly.

Can you upload a sample solution (against NorthwindIB please) reproducing the issue?

Regards,
   Silvio.


Posted By: Testing
Date Posted: 27-Sep-2011 at 1:29am
Hi,

The thing is working against northwindIB.

I've tested some little more and found out that you CAN'T filter the data directly from the Entity Framework

But first of all you need to fetch all the data first into a list..
And after that, filtering the data..

Is there any way to do this immediately?


Thankyou!



Print Page | Close Window