Server.Mappath in C# classlibrary

前端 未结 7 1644

How can i use the server.mappath method in a C# class library class ,which acts as my BusinessLayer for My ASP.NET WEbsite

相关标签:
7条回答
  • 2020-12-13 13:08

    Maybe you could abstract this as a dependency and create an IVirtualPathResolver. This way your service classes wouldn't be bound to System.Web and you could create another implementation if you wanted to reuse your logic in a different UI technology.

    0 讨论(0)
提交回复
热议问题