This Visual Basic example demonstrates how to use the Tortuga Technorati API ActiveX component to search for blogs matching a query.
The free Tortuga ActiveX can be downloaded here: ActiveX Download
' Technorati SearchQuery Visual Basic Example
Dim tech As New Technorati
' An API key is required. You can get the Technorati API Key
' from http:'www.technorati.com/developers/
tech.Key = "aaaaaaaaaaaaaaaaaaa"
' Find blogs about data compression
Dim rssDoc As Rss
Set rssDoc = tech.SearchQuery("new york yankees")
If rssDoc Is Nothing Then
MsgBox tech.RawQueryResponse
Else
' Success! Let's get some information...
' The RSS response always has a single channel. The information will
' be contained within the channel.
Dim channel As Rss
Set channel = rssDoc.GetChannel(0)
' Iterate over the blogs linking to our target blog:
For i = 0 To channel.NumItems - 1
Dim item As Rss
Set item = channel.GetItem(i)
blogTitle = item.GetString("title")
blogUrl = item.GetString("link")
List1.AddItem blogTitle
List1.AddItem blogUrl
List1.AddItem "----"
' There are many other field you could retrieve for each search result:
Description = item.GetString("description")
DateCreated = item.GetDate("tapi:created")
numInboundBlogs = item.GetInt("tapi:inboundblogs")
numInboundLinks = item.GetInt("tapi:inboundlinks")
atomUrl = item.GetString("tapi:atomurl")
rssUrl = item.GetString("tapi:rssurl")
' ...
Next
' The RSS response is also available in the RawQueryResponse property.
Text1.Text = tech.RawQueryResponse
End If