none
Removing Activity Feeds via the API

    Question

  • I've managed to create a whole load of activity feeds as part of our application installed via a feature, but how do I remove them? I've tried the

    actMgr.ActivityApplications[app.ApplicationId].Remove();  method but apparently it throws a not implemented exception.....

    Is there a way to remove an Activity App that is implemented?

    Monday, May 24, 2010 8:03 PM

Answers

  • No, there is not. I filed a bug on that and the answer is that it's a placeholder method for soft deletes in a future version. So no, there is NO WAY to remove a custom application. If this is a pure dev environment, you can clean your custom activity feed artifacts using the following (unsupported) database scripts on the profile database, although these clear out the ENTIRE activity feed.

    delete ActivityEventsPublished
    delete ActivityEventsConsolidated
    DELETE [dbo].[ActivityPreference]
    delete [ActivityTemplate] where activitytemplateid > 22
    delete [ActivityType] where ApplicationID > 3
    delete [ActivityApplication] where ApplicationID > 3
    


    Daniel Larson, SharePoint MVP, MS Press Author, NewsGator Software Developer Check out my books on Amazon: - Inside Microsoft Windows SharePoint Services 3.0 (with Ted Pattson) - Developing Service Oriented AJAX Applications on the Microsoft Platform (.NET 3.5, WCF, Microsoft AJAX)
    • Marked as answer by PeteD Friday, May 28, 2010 2:09 PM
    Thursday, May 27, 2010 5:24 PM

All replies

  • No, there is not. I filed a bug on that and the answer is that it's a placeholder method for soft deletes in a future version. So no, there is NO WAY to remove a custom application. If this is a pure dev environment, you can clean your custom activity feed artifacts using the following (unsupported) database scripts on the profile database, although these clear out the ENTIRE activity feed.

    delete ActivityEventsPublished
    delete ActivityEventsConsolidated
    DELETE [dbo].[ActivityPreference]
    delete [ActivityTemplate] where activitytemplateid > 22
    delete [ActivityType] where ApplicationID > 3
    delete [ActivityApplication] where ApplicationID > 3
    


    Daniel Larson, SharePoint MVP, MS Press Author, NewsGator Software Developer Check out my books on Amazon: - Inside Microsoft Windows SharePoint Services 3.0 (with Ted Pattson) - Developing Service Oriented AJAX Applications on the Microsoft Platform (.NET 3.5, WCF, Microsoft AJAX)
    • Marked as answer by PeteD Friday, May 28, 2010 2:09 PM
    Thursday, May 27, 2010 5:24 PM
  • That's pretty poor isn't it. When you're an ISV having a good upgrade and uninstall story is kind of fundamental to marketing products based on SharePoint.

    I really hope MS sort this sooner rather than later.

    Friday, May 28, 2010 2:09 PM
  • Any news on this bug -- I have client who has compliance requirment to remove any innappropriate content that appears in SharePoint - unless this method gets implemented, I can't see any other way to remove an inappropriate feed item other then to delete all of the offender's colleagues profiles -- that's definitely too drastic.

    If no news - a bug ID would be helpful.  Thanks Daniel.

    Thursday, January 27, 2011 8:43 PM
  • Daddyl-- deleting an item is different than deleting an application. That can be done, however not entirely, you kind of have to understand SharePoint's NewsFeed data storage to get this cocept-- an activity event is duplicated once for the author and additional times for every recipient of the event. It's a lot of duplicate data but it's fast.

    NewsGator Social Sites has a pretty good implementation of your compliance requirement-- Daddyl, I recommend you check it out. (Disclaimer: I work for NewsGator... it's my code:) )

     


    Daniel Larson SharePoint Architect at NewsGator Technologies, Author for Microsoft Press, Father of VI and Eli
    Thursday, January 27, 2011 11:04 PM