Disable Blocked File Protection Control in Windows Vista

Posted by andy gaskell on Jun 26th, 2008

In my neverending quest to make Vista more usable, I finally caved and took the time to figure out how to disable Blocked File Protection Control. This “feature” requires you to unblock files you download before they are usable (for the most part). This is a bad decision in my opinion – I decided to download a file and of course I’m going to want to work with it. I don’t want to figure how how to unblock before I can use it. What a pain – anyway enough with the rant.

Unblocking files sucks

If you want to be able to use your files after you download them, you’ll need to either use the Group Policy Editor described here in as Method #3 or edit the registry.

Unfortunately I happen to be running Windows Vista Home Premium on one of my systems – this means no gpedit. The entry we need to set is:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments\SaveZoneInformation

This value needs to be a DWORD set to 1. You can enter this manually or download the reg file and “Unblock” your last file! Be sure to close all instances of Internet Explorer or reboot your computer after making the change to your registry.

Using the digg API in an ASP.NET Page

Posted by andy gaskell on Apr 20th, 2007

Digg released their API yesterday – I haven’t really done much with RESTful web services because in the .net world, most of the time SOAP/WSDL is used. I thought a very basic RESTful web service project would be useful for other .net developers.

This example gets a list of all topics that digg offers. The code is pretty simple:

// Create the web request, change the appkey to for your applications
HttpWebRequest request = WebRequest.Create("http://services.digg.com/topics?appkey=http%3A%2F%2Fgaskell.org") as HttpWebRequest;

// won't get a response from digg if UserAgent is not set
request.UserAgent = ".net"; 

// Get response
using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)
{
     // Get the response stream
     StreamReader reader = new StreamReader(response.GetResponseStream());

     DataSet ds = new DataSet();
     ds.ReadXml(reader);

     this.topicsGridView.DataSource = ds.Tables[1];
     this.topicsGridView.DataBind();
}    

Download the project or check out the live demo

Now with 100% more .net

Posted by andy gaskell on Apr 18th, 2007

I host my blog on the fantastic WordPress blog platform which typically runs on the LAMP stack. That means I can’t put up live demos of my .net posts so I created a new .net playground at http://dotnet.gaskell.org. I’ll have live examples of all of my projects as well as project downloads.

To get things started here’s a live demo of the digg style paging in asp.net project I created.

-