Hi,
In Samples for Silverlight DV, for XamPivotGrid, there is a nice sample showing how to save and load views.
How do I save the settings class (SavedPivotGridView) to the database ?
I tried to serialize it as Xml, but it does't work (classes inside are not serializable). I also tried using PersistenceManager, but it didn't store the collections' content (Rows, Columns, Filters, Measures).
Thanks,
Alex
Hi, Achim,
The XMLA data source works in a different way.
The browser hangs because waitOne suspends the whole thread and the pivotgrid cant expand its members (which means the event that stops the waiting never fires). If you want to use XMLA data source you need to take the expansion process in a separate thread.
I'm attaching a sample that expands filter members up to a certain level with XMLA data source. You will find all you need there.
If you cant figure out what to change in the serialization sample I'll post the modified version tomorrow.
All the best,
Atanas
Hello Atanas,
your example code is working now. In my scenario I the member expansion hangs my browser. I am working with an XmlaDataSource together with a SSAS 2008 cube. I pin-pointed the issue to the ManualResetEvent used in the ExpandMembers method.
ManualResetEvent manualResetEvent = new ManualResetEvent(false);filterViewModel.LoadFilterMembersCompleted += (sender1, e1) => manualResetEvent.Set();...manualResetEvent.WaitOne();
When working with the XmlaDataSource the event does not seem to get fired and the browser waits forever. It would be great if you could also test with your AdventureWorks XmlaDataSource used in one of the examples. I could reproduce this behaviour using your AdventureWorks Cube.
With kind regards,
Achim
p.s. thanks for your great support!
Hi Achim,
The problem is solved. The issue was in the save algorithm of the sample. I'm attaching the corrected version of the SavedPivotGridView class. After you extract the file just replace it in the original solution.
Nasko
Thanks a lot Atanas
Great find Achim, this is indeed a bug.
I think it is only sample related, not in the control itself. I'll be looking into the issue right away. And will let you know when that is fixed.
Thank you,