We are currently using a third party DLL, that looks for a license file in the working directory of the application. When the code is run out of a typical C# application, the DLL is able to pick up the license file located in the same directory (\bin\
). When an ASP.NET application is running that same code under IIS, it fails due to licensing issues. The only work around we have found has to place the license file in Windows\System32\inetsrv
.
It seems as though the DLL is referencing the license file using a simple file.open("*.lic*);
, and because IIS is using inetsrv as the working directory (https://stackoverflow.com/a/16485227/693671), it simply looks there. Is there any way to change the working directory of an IIS application?