Members: exception when clicking "Most viewed"

Vote:
 

Dear fellow Relate+ developers,

we are working on a Relate+ solution for a customer, and they have reported that when pressing the "Most viewed" linkbutton in the member list, it fails.

It looks like it doesn't work in the demosite either, have a look at: http://relate.episerver.com/Members/

..it looks like the call to the "GetVisitedItems" method returns a Forum-page in between the Member pages and it throws an exception in the foreach loop below it.

Has anyone else experienced this problem? Any solutions? :-)

Regards,
Anders

#41937
Aug 04, 2010 12:12
Vote:
 

Hi Anders,

Most Viewed has never caused me any trouble. But as you get a Forum-page in between the Member pages it sounds like Type might not be specified when calling GetVisitedItems. What does your call look like?

Working example:

// Get the most viewed members
VisitableEntityCollection visitedItems = VisitHandler.GetVisitedItems(typeof(Community.MyPage.MyPage), page, ucMembers.PageSize, Utils.CacheTimeOut.MostViewed, out totalItems, new VisitableEntitySortOrder(VisitableEntitySortField.NumVisits, SortingDirection.Descending));
    

Karoline

#42031
Aug 06, 2010 10:09
Vote:
 
  

Hi,

I have specified typeof(Community.MyPAge.MyPage) just as you have in your example, but still its giving me a forum page in between...

 

here is my function call:

 VisitableEntityCollection visitedItems = VisitHandler.GetVisitedItems(typeof(EPiServer.Community.MyPage.MyPage), page, ucMembers.PageSize,
                                                                                  CacheTimeOut.MostViewed, out totalItems, new VisitableEntitySortOrder(VisitableEntitySortField.NumVisits, SortingDirection.Descending));

Regards,
Anders

#42084
Aug 07, 2010 10:45
Vote:
 
  

Hi,

I have specified typeof(Community.MyPAge.MyPage) just as you have in your example, but still its giving me a forum page in between...

 

here is my function call:

 VisitableEntityCollection visitedItems = VisitHandler.GetVisitedItems(typeof(EPiServer.Community.MyPage.MyPage), page, ucMembers.PageSize,
                                                                                  CacheTimeOut.MostViewed, out totalItems, new VisitableEntitySortOrder(VisitableEntitySortField.NumVisits, SortingDirection.Descending));

Regards,
Anders

#42085
Aug 07, 2010 10:47
Vote:
 

I believe this is caused by a known issue, you can get a hotfix from EPiSupport.

#42104
Aug 09, 2010 10:40
This thread is locked and should be used for reference only. Please use the Legacy add-ons forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.