1
다음 코드를 사용하여 서비스를 설치합니다.AssemblyInstaller 서비스가 dll 파일에 대한 액세스를 차단하도록 설치합니다.
string[] commandLineOptions = new string[0];
System.Configuration.Install.AssemblyInstaller installer = new System.Configuration.Install.AssemblyInstaller(path, commandLineOptions);
installer.UseNewContext = true;
installer.Install(null);
installer.Commit(null);
설치 후에는 서비스가 포함 된 dll 파일을 제거하는 동안 설치가 잘되지만 액세스가 거부되어 수행 할 수 없습니다. 응용 프로그램을 닫으면 문제가 사라집니다 (서비스가 설치되어 있음). 그것을 해결하는 방법?
모두 작동하지 않습니다 – quarandoo