I ran into this problem while trying to model some demo code for an ASP.Net application.
I'm running Vista Enterprise x64 and Visual Studio x64 2008.
When I tried to create a new web application in VS 2008 and browse it, I'd get the above error. The fix was to change the application pool to run in 32 bit.
Right-Click on My Computer --> Manage
Expand Services and Applications
Select Internet Information Services, then local Application Pools under Connections.
Right click on DefaultAppPool, Advanced Settings, and set the 32bit mode to True:
Hopefully this will be useful to others out there.
MikeH... Another Geek in Need...