Reputation: 1380
I'm running VS2010 pro, and I downloaded a sample Silverlight app written in an older version. I did the conversion but now when I go to run it, I get this error. I searched the net, the only recommendation I found was to add a reference to "System.Net" (which didn't make sense, but I did anyway), but this didn't help. The offending code:
public System.Net.CookieContainer CookieContainer {...
Upvotes: 3
Views: 1370
Reputation: 547
CookieContainer Class Namespace: System.Net Assembly: System (in System.dll) Supported in: 4, 3.5 SP1
CookieContainer still exists.
Try deleting the reference in your project then add System.net again.
Upvotes: 0
Reputation: 189505
The System.Net dll is usually referenced by default but perhaps it wasn't in the older project. Check the version number is 2.0.5.0 and that the file path is something like:-
c:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\System.Net.dll
Upvotes: 1