Refactor; use .NET classes where possible

you have to replace spaces in the url by "%20" somewhere.