Project Reference in VS 2005 causes: Could not find file 'Microsoft.Windows.CommonLanguageRuntime, Version=2.0.50727.0'

by Bill Sempf 31. August 2005 12:07

Interesting little bug that I ran into today.  If you reference a Windows Forms project from another Windows Forms project using the Project Reference dialog, you will get this weird error:

Could not find file 'Microsoft.Windows.CommonLanguageRuntime, Version=2.0.50727.0'

There is actually a KB on it, but it doesn't show up in Google, or of course in MSDN search:

http://support.microsoft.com/?kbid=907757

Learn something new every day.  Service Pack 1, anyone?

Tags:

Biz | VB | C#

Don’t underestimate the My object

by Bill Sempf 1. August 2005 12:06

Need a file from a secure network share?  Trying to actually understand the NetworkCredentials classes?  Good freakin luck!
I went through the snippets, searched google, and read the MSDN library cover to virtual cover before I just dialed in.
My.
Computer.
Network.
DownloadFile?  Does it have an overload with username and password?
Well I'll be a son of a ...
Final code:

My.Computer.Network.DownloadFile("\\192.168.1.3\share\point\test.xls", "c:\text.xls", "user", "password")

Works like a charm.

Tags:

VB

Husband. Father. Pentester. Secure software composer. Brewer. Lockpicker. Ninja. Insurrectionist. Lumberjack. All words that have been used to describe me recently. I help people write more secure software.

Find me on Mastodon

profile for Bill Sempf on Stack Exchange, a network of free, community-driven Q&A sites

MonthList

Mastodon