建了个c#服务,安装时添加了自定义操作后在安装文件夹下面会生成一个*.InstallState文件,为啥呢?http://topic.csdn.net/u/20080412/18/3FEC3D2B-0414-49F5-8FB9-BB908932C5E2.html这个好像问过但也没说清

解决方案 »

  1.   

    <SOAP-ENV:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:clr="http://schems.microsoft.com/soap/encoding/clr/1.0" SOAP-ENV:encodingStyle="http://schemas.xmlsoap打开看都是些奇怪的东西
      

  2.   

    I have an MSI file that I have created using a Visual Studio Setup Project. The installed generates an .InstallState file in the application directory. Is there a way to have this file generated in a different location rather than the default location?难道这个文件是必须的?以前没见过This should also work by specifying /InstallStateDir="c:\myfolder" from the commandline (see KB946503). However, InstallContext is converting all parameter names to lowercase which breaks the following code from AssemblyInstaller, expecting to find the mixed case parameter name:private string GetInstallStatePath(string assemblyPath)
    {
        string str2 = base.Context.Parameters["InstallStateDir"];
        assemblyPath = Path.ChangeExtension(assemblyPath, ".InstallState");
        if (!string.IsNullOrEmpty(str2))
        {
            return Path.Combine(str2, Path.GetFileName(assemblyPath));
        }
        return assemblyPath;
    }Setting Context["InstallStateDir"] would possibly work for saving the state; however, as the state is loaded before Uninstall can modify the context, this is no viable solution until Microsoft fixes the above AssemblyInstaller.GetInstallStatePath method.