If you want to extract structured data from Wikipedia, you may consider using DbPedia http://dbpedia.org/
It provides means to query data using given criteria using SPARQL and returns data from parsed Wikipedia infobox templates
Here is a quick example how it could be done in .NET http://www.kozlenko.info/blog/2010/07/20/executing-sparql-query-on-wikipedia-in-net/
There are some SPARQL libraries available for multiple platforms to make queries easier