server.mappath in class library c#



You need to add a reference to the System.Web assembly.


string fullPath = System.Web.HttpContext.Current.Server.MapPath("/FileName.png");    
FileName.png  - Set your short path of file and your will get full path of file.

0 Comment's

Comment Form

Submit Comment