CS MVP's
Community Servers Most Valued Professionals

Browse by Tags

  • Create RSS and Atom Feeds with LINQ and WCF Syndication in .NET 3.5

    Last week after finishing manuscripts of my book , I promised to get back to regular blogging and give more stuff about programming and .NET especially about newly released .NET 3.5 so here you go! It's been a long time since the last time that I sent a blog post with programming codes, isn't it?! One of very nice additions to .NET 3.5 is the Syndication library for Windows Communication Foundation which lets you create RSS and Atom feeds and deal with data from existing feeds easily. You...
  • Visual Studio Add-in C# Code Template

    Yesterday, Bill Bridges (Development Editor of my new book) sent me an email about a problem in one of the recent chapters of my upcoming book about Visual Studio Extensibility. The problem, that had taken half an hour of his time to get fixed was a simple formatting problem in one of source code samples. A a non-technical man, he was honest to change all lines of a source codes manually one by one. Book publishers like to use spaces for code indentations not tabs. In that chapter, one code sample...
  • Unit Testing Generic Lists

    If you do unit tests frequently, know that unit testing a generic list is a very common scenario because generic lists are a common part of today's codes in the .NET world. Testing the equality of two generic lists isn't as easy as easy testing the equality of two objects from two simple types. In order to test two generic lists, you need to follow one of two approaches that I describe in this post. One of them is easy and can be done quickly and the second one may need more effort. Background...
  • Self-Hosting WCF Services in Windows Services

    You know that there are two common ways to host a Windows Communication Foundation service as a self-hosted service or in IIS. But there is a division of self-hosting that is a bit different and that is self-hosting a WCF service in a Windows service. In this post I talk about this shortly. Self-hosting a WCF service in a Windows service is pretty easy. The key point is deriving the service class from ServiceBase class to implement the Windows service and implementing the service contract both together...
    Filed under: , ,
  • Use WMI Provider in Windows Communication Foundation

    If you can recall from my older posts, I had discussed about tracing and message logging in Windows Communication Foundation before. There is another option to monitor diagnostics of a WCF application using Windows Management Instrumentation (WMI) and is the topic of this post. There are three steps to use WMI provider in WCF: building and configuring a service, building a client to use this service and viewing WMI information. Service First we need to create a service. The service contract for my...
    Filed under: , ,
  • CS Dev Guide: Emailing in Community Server 2007

    Back in September 2006 I wrote a CS Dev Guide post about emailing in Community Server 2.1 . In Community Server 2007 emailing has changed a lot and now we can consider it as something completely new. I can say that Ken Robertson has done a great job on enhancing email features in Community Server 2007 and thank to his additions, now emailing is extendable and you can customize emailing features easily. In this post I want to talk about emailing in Community Server 2007 which is now known as MailRoom...
  • How to Write a Custom MSBuild Task

    When working on a chapter of my upcoming Professional Visual Studio Add-ins and Extensions book, I wrote about MSBuild tasks and writing a custom task for custom scenarios. Let me write a short description about it here as well. Writing a custom MSBuild task consists of creating a class in an assembly which implements ITask interface located in Microsoft.Build.Framework assembly. This ITask interface class has two properties and a method to implement. BuildEngine and HostObject are two properties...
  • DataSet.WriteXmlSchema and DataSet.ReadXmlSchema Issue

    As a part of my implementation of Google Safe Browsing API in Subkismet project, I was working on an XML provider to store data in XML files and load them later. One of approaches that I tried to test was using a DataSet to store my data as XML and load it from the file to a DataSet and generally building my provider based on XML manipulation features of DataSets. When working on this code, I got in a trouble that I write in this post with a solution for that even though I didn't keep using this...
    Filed under: , ,
  • Unit Test Visual Studio Dialog Boxes with DialogBoxPurger

    When working on the book , I noticed something very nice in Visual Studio 2008 SDK. Maybe it was a part of Visual Studio 2005 SDK but I haven't tested it! Visual Studio SDK installs a code template for unit testing Visual Studio dialog boxes (and some other common scenarios) by default. When working on VS related stuff, this comes very handy to let you unit test your UI and results easily. This code template is DialogboxPurger class which will be added to your unit test projects and works closely...
  • ReceiveActivity in Windows Workflow Foundation 3.5

    Last week, I talked about SendActivity in Windows Workflow 3.5 and today talk about ReceiveActivity. This activity can be used in WCF services in order to listen for a specific service method and handle its logic in a workflow. ReceiveActivity can work as a container for other activities and hold them as part of method logic. It gets method parameters via properties or fields and sets the result of the method in a field or property. When service method is called by the client, it returns this field...
    Filed under: , , ,
  • Silly Recursion Examples

    One of guys at our military office is learning programming from the base at 25!! Sometimes he asks me some questions and wants me to check his codes. Today he showed me one of his codes for Factorial recursive example and asked a few examples! Seeing his example, I suddenly remembered something that I had read in Code Complete 2 about two silly examples that we see in computer-science textbooks for recursion and they are Factorial and Fibonacci sequence algorithms. Steve McConnell is 100% right in...
  • CS Dev Guide: Forum Moderation

    You know that the forum application in Community Server is the most powerful and important application in it. There are many features that make this application great and one of them is the rich set of moderation tasks provided for forum moderators and users. There are many moderation features that you can use in Community Server forums such as approving, deleting and moving a post or joining or splitting a thread. These are all coming from a set of API that will be covered in this post. There are...
  • RFC2396 URL 1.0 Beta 1 Released

    A few weeks ago, I announced a new open source project for RFC2396 URLs which is a part of our implementation for Google Safe Browsing API in Subkismet. Today I'm happy to announce the first public Beta release of this component. Happy because I never thought that I can release this sooner than 3-4 months! This first release contains everything necessary for our Subkismet project. For now, it only supports canonicalization of URLs based on RFC2396 specification with an exception: it doesn't...
  • SendActivity in Windows Workflow Foundation 3.5

    Windows Workflow Foundation in .NET Framework 3.5 comes with two new activities: SendActivity and ReceiveActivity. These are two new services to work with WCF services. The first one, SendActivity, can be used to send requests to WCF services and the second one, ReceiveActivity, can be used to receive the response from services. In this post I talk about the SendActivity and in one of upcoming posts, I'll cover ReceiveActivity. Create a Service First, let me create a WCF service for this example...
    Filed under: , ,
  • Organize Usings in Visual Studio 2008

    One of new features for language editor of Visual Studio 2008 is the Organize Usings option. This is a simple option that lets you organize Using references in your code. This option lets you to remove unused Usings and sort them or both. You can get access to this option just by right-clicking on the code editor. If you choose to remove unused Usings, it removes all unused Usings and just keeps what you need. On the other side, if you choose to sort Usings, it will sort them alphabetically. Since...
1 2 3 4 5 Next > ... Last »
Community Server MVP's © 2006-2008
Powered by Community Server (Commercial Edition), by Telligent Systems