Modify forum groups

To modify a forum group, you must perform the following:

  1. Get an instance of the manager.
    Get an instance of the ForumsManagerobject.
  2. Get the specified forum group.
    Get an instance of the forum group. For more information, read For developers: Query forum groups.
  3. Modify the instance of the group.
    Update the values of the properties of the group.
  4. Save the changes.
    Save the changes to the manager.

Following is a code example:

C#
using System;
using Telerik.Sitefinity.Forums;
using Telerik.Sitefinity.Forums.Model;

namespace SitefinityWebApp
{
    public class ModifyForums_ModifyForumGroup
    {
        public static void ModifyForumGroup(Guid groupId, string newDesription)
        {
            ForumsManager forumsManager = ForumsManager.GetManager();

            ForumGroup forumGroup = forumsManager.GetGroup(groupId);
            forumGroup.Description = newDesription;

            forumsManager.SaveChanges();
        }
    }
}
Want to learn more?
Enhance your Sitefinity skills by enrolling in free training sessions. Become Sitefinity certified through Progress Education Community to strengthen your professional credentials.
New to Sitefinity?