1. I created a new Class Library Project
2. Add System.Web Reference by
Right Click Project => Add Reference => Click .Net Tab => Choose System.Web
3. Then I tried following and it worked
public class Class1
{
public void A()
{
string s = System.Web.HttpContext.Current.Server.MapPath("prequal.xml");
}
}
May be you should remove reference and again add to make it work