To implement twitter search in C# that uses oauth for authentication, first we need a C# oauth implementation, and a JSON parser for extracting results. For oauth implementation I’m using Twitter oAuth with .NET by Shannon whitley and for parsing the results JSON parser by Procurious and i have to say that this post is just a bit refined implementation of Parsing Twitter JSON data in C# by Jamie’s Digital Blog.
To get started with twitter needs you to authenticate your application before you could use twitter API’s search feature, to authenticate an application needs to initialize a oAuthTwitter object so that it is accessible through out the class like
Now since we have obtained the authentication we can use this oAuth to search twitter
Now we have the 100 search results stored in a string result in JSON format, we will use JSON parser for extracting the values of each tweet
You can download the complete source code along with oauth and JSON parser implementations from https://sites.google.com/site/coderbuddy/myReserach.zip?attredirects=0&d=1
You may need to make some modifications to the code like providing the consumer key and consumer secret before working with the code