System.Web.UI not available in console app?
Im trying to write a quick console app that outputs data to an HTML file, however im having trouble accessing the System.Web.UI namespace.
Adding System.Web to my references places a warning icon on top of the reference n开发者_开发知识库ame in the solution explorer and System.Web is not available in the .NET reference list (in order for me to actually add it to the project I have to go to the object browser and add it from there).
Anybody have any ideas about what I could be missing?
Thanks alot people!
In Visual Studio 2010 the default target framework for Console Applications is ".NET Framework 4 - Client Profile" which doesn't include System.Web. Change it in the project properties to just '.NET Framework 4' and you can add the reference.
精彩评论