How to use Bing Search API

I have subscribed to Bing Search API on the Azure Data Market and successfully added the connection to the LinqPad (at least it populated the data sources from it). But, when I try to query any of the data sources, I'm greeted with a "The type or namespace name 'BingSearchContainer' does not exist in the namespace 'LINQPad.User'" message. I tried to compile the BingSearchContainer.cs file from the data market and give it to LinqPad, but still the same problem.

As a bonus question, can anybody recommend another free source from the MS Data market that is fun to play with ? ;)


  • I've identified the problem and fixed it in the latest beta:

    Bear in mind that after connecting, that you won't simply be able to call a "Web" method in LINQPad to query the web, because the WCF Data Client's proxy generator doesn't generate methods for operations. (You'll experience exactly the same problem in Visual Studio.)

    Instead, execute the following query to run a web search:
    CreateQuery<WebResult>("Web").AddQueryOption ("Query", "'LINQPad'")
    And bear in mind that if your search expression contains special characters, you'll need to escape them:

    CreateQuery<WebResult>("Web").AddQueryOption ("Query", "'" + Uri.EscapeDataString ("LINQPad#") + "'")
Sign In or Register to comment.