Blogging, CommunityServer

Getting formatted c# code into CommunityServer

After looking at a couple of different solutions I ended up using csharpformat for one of my previous posts, and I will probably keep using it. It’s not perfect, most of all I would have liked getting CopySourceAsHtml working, since judging from the description that would make the snippets in the blog look exactly like in Visual Studio, which is what I really want. However it just keeps throwing exceptions and I am in no mood of debugging it at the moment. Csharpformat with some small adjustments to the css file does the trick, and most importantly it makes the code itself searchable and copyable instead of it being an image – which isn’t really helping anyone. CSharpformat seems to also be mirrored here, and is available as a VS.NET 2005 plugin here, although since it builds on the same principles I am not sure what extras it gives you, but then I haven’t tried it.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s