Posting C# Code Snippets
After seeing it on Greg Young's blog, and after getting sick of my code snippets in blogger not working, I decided to try syntaxhighlighter. To find out how to use it with blogger read the usage guidelines and more importantly this page which tells you how to get setup to use it with blogger.
Anyway here is an example:
public class DomainChangeTrackingService : IDomainChangeTrackingService
{
public void ProcessMessage(DomainChangeMessage message)
{
new DomainChangeMessageRepository().Save(message);
Debug.WriteLine("Nothing");
}
}
I like the "Paste from Visual Studio" plugin for Live Writer:
ReplyDeletehttp://gallery.live.com/liveItemDetail.aspx?li=d8835a5e-28da-4242-82eb-e1a006b083b9&bt=9&pl=8
It preserves your color scheme from VS, whether it's XML, ASPX, or C# files. It's the only one that's consistently worked on the blog site as well as through feed readers.
Excellent I'll give it a shot.
ReplyDeleteI did notice that syntaxhighlighter does not work with (some?) feed readers which is another reason for me to give this one a shot.
ha, finallly something on your blog i understand :-) It looks very professional.
ReplyDeleteUnfortunately Stewart pointed out it doesn't work in bloglines or in Firefox. Bah!
ReplyDelete