SharePoint Forums... go get 'em

I’m very happy to say that the SharePoint Forums Web Part is ready for you to install. I cleaned a few things up from the last week with the testers but most people reported no problems and only suggestions (which is always a good thing). There were a couple of problems with permissions however if you follow the installation instructions below you should be golden.

I do apologize for not putting together an MSI or something. I did go down that path using WPPackager, however two problems. One is I couldn’t get the permission setup correct and the second thing is that the Forums uses a common library that I’m giving out which needs to go into the GAC but the Forum Web Part assemblies can go into the bin directory. I couldn’t find a way to split this up and then couldn’t get WPPackager to just package a regular file so it either meant doing it by hand (which is what I did) or building a two installers using two different tool sets.

In any case, installation does require a bit of configuration but it’s painless. If some adventurous soul out there wants to put together an installer I’ll throw you a cool SharePoint prize.

You can download version 1.0.0.0 of the Web Part from here. For those that have previous versions installed, please remove them and delete your forums. If you really want to retain the old forums I can tell you how to do this but email me privately as it involves some extra steps.

Here are the web part installation instructions. These instructions are also in the zip in a text file called DRINKME.TXT.

Step 1
Install “BilSimser.SharePoint.Common.dll” to the GAC

Step 2
Copy "BilSimser.SharePoint.WebParts.Forums.dll" and "BilSimser.SharePoint.WebParts.Forums.Core.dll" to your SharePoint web site bin directory (if it's the default, it's c:\inetpub\wwwroot).

Step 3
Add the following SafeControl entries to your web.config file:
<SafeControl Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32" Namespace="BilSimser.SharePoint.WebParts.Forums.Controls" TypeName="*" />
<SafeControl Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32" Namespace="BilSimser.SharePoint.WebParts.Forums" TypeName="*" />
<SafeControl Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32" Namespace="BilSimser.SharePoint.WebParts.Forums.Controls.Common" TypeName="*" />
<SafeControl Assembly="BilSimser.SharePoint.WebParts.Forums, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e516dadc23877c32" Namespace="BilSimser.SharePoint.WebParts.Forums.Controls.Base" TypeName="*" />

Step 4
Add the following to a custom policy file (PublicKeyBlob split for clarity but needs to be one line):
<CodeGroup
 class="UnionCodeGroup"
 version="1"
 PermissionSetName="FullTrust">
<IMembershipCondition
 version="1"
 class="StrongNameMembershipCondition"
 PublicKeyBlob="0024000004800000940000000602000000240000525341310004000001000100F15CA89A
80D45C052CC5003DDAD661CEA98168E5B12A7BEC2A8B455D1E7D043C9248BC192A16B02B4D1CCF41738C31797
CFFED01C70EE6247222243FA3B10706368EDE73C57BAF586582F83CB9391DA711DFF5B8169A9AD6169D6023B5
C6572136233AC331010CE4C808143B2E2AB18FE59A872340DB76F71180623789336DAB">
</IMembershipCondition>
</CodeGroup>

IMPORTANT!
This entry needs to go AFTER the FirstMatchCodeGroup and BEFORE the ASP.NET UnionCodeGroup!

Step 5
iisreset (or recycle your AppPool)

Step 6
Import SharePointForums.dwp onto a WSS site or SPS area page where you are an Administrator.

Step 7
Configure, and have fun!

I’ll post a quick set of docs (somewhere) on doing basic stuff but watch for blog entries on various tricks you can do. Email me at bsimser@shaw.ca if you have problems, questions, suggestions, small marsupials, concealed logging chains, etc.

17 Comments

  • Good stuff! I'm interested in seeing how it was done. I wouldn't be a true customer (yeah, I know it's free) if I wasn't asking about features. Have you considered how much work it take to add some kind of search?

  • After installing the Forum I get the standard popup asking for credentials when I try accessing the page where the forum is added. However the page does not seem to like my credentials...even thought they are correct...



    Every other page on the site works fine...



    Any idea what the problem might be?

  • I have the same problem with credentials.

  • Bil,



    Does it really need the GAC for the common DLL, and Full Trust for the rest? Do you have plans to determine the most restrictive permissions you can apply for the app's trust level?



    I'd love to make this available to our hosting customers, but we won't run anything in the GAC if we can avoid it. Ditto with FullTrust.



    Finally, watch out for that wombat behind you...

  • dino, Jonas -- what identity are you using for the app pool that the SharePoint IIS web site is assigned to?

  • @Dustin: The common dll is meant to be a building tool that anyone can use (source code, API docs will be available) so they can use it for their applications so it's considered a helper framework. Putting it in the GAC is the only way I can version it, otherwise multiple projects (not only my own) will have to be recompiled whenever a new version is avaialble.



    As for the more restrictive permissions for the web part, I will look at knocking down the FullTrust to something more manageable. It's one of those things you need a whole day to sit down, try, fail, repeat when it comes to determining what permissions you need (at least that's what I've found) and I haven't got to it yet.

  • I'm not sure what the issue is with the credential problem. First off is it happening with an admin user or regular users? I know when I would use a local user I would (sometimes) be asked for them, but once I entered them once it wouldn't ask me again.



    Of course, everyone's setup is different and I'll try to figure out how to accomodate every scenario and see what I can do.

  • @Jason: Search will be added as it was a minor thing to do, but I didn't get to it in the first cut.

  • I asked about the app pool identity because I was seeing the same issue (repeated requests for username\password) until i changed the app pool identity to NOT be the network service. This was the setup on my personal SharePoint testbed -- our deployed server wouldn't have this problem because we have a dedicated account.



    Thanks for the update, Bil.

  • @Jason: Yes, if your AppPool is running as NETWORK_SERVICE it generally has very low privledges. It's recommended you have a domain id for the AppPool, or barring that at least a local admin account (although if you need to index remote resources, this doesn't work).

  • Yepp, we're running under the Network Service... And we need to index remote content. Is there any hope for us to use your web part

  • Congrats Bil! Got a weird thing happening... the first time I add it to a portal area, it throws the Web Part Maintenance Page. Once I delete the Error web part and readd it again, it works fine.

  • I might have missed if it was posted somewhere else, but is this web part compatible with .net 1.1?

  • Yes, it only runs with .NET 1.1. There is no 2.0 version available yet.

  • I can't get it to run. Everything seems configured correctly until after I import the dwp. When I then drag the part onto a page I get "A Web Part or Web Form Control on this Web Part Page cannot be displayed or imported because it is not registered on this site as safe." This is for a WSS site so the only thing I can think is that I might have the other dll's on the wrong bin?
    Any ideas?

  • I want to migrate the whole farm from a server which has MOSS 2007 and which contains workflows,lists and do library with attahments and web parts and many sites... to another server which has only WSS 3.0 installed into it..
    Is there a way to do and also to restore back ?

  • I have one project List which is sharepoint BCS list with filter descripter companyID.When i am try to reading project list programetically passing with default value it not passing the value to the readlist .But from view if i pass default value it is working .Can you please help me to get this problem .Please let me know if anything else.
    Regards,

Comments have been disabled for this content.