This is a fairly common error I have experienced with BuddyPress group forums and have seen others with this issue as well. When trying to create a new topic, you get the following error: “There was an error when creating the topic.” Richie posted this solution in our Premium DEV forums, and I thought I’d share it here. Sometimes this error is caused by a duplicate forum id.
Go to: phpmyadmin > yourdatabase > wp_bp_groups_groupmeta
Find the group you’re attempting to post to and then delete the forum_id value. Go back to your group on the front end. When logged in as admin of the group, go to settings and re-enable your forums. It will save a new forum_id for you and your posts should start working. This is a solution for BuddyPress groups that are starting a fresh new forum, not for groups with forums that have existing posts.