在一台机子上编写的C#程序到了另一台机子上重新编译时出现“无法在证书存储区中找到清单签名证书”错误,在网上寻找到以下方法:
第一种办法:
在“解决方案资源管理器”中的项目上点右键--属性--签名,把“为ClickOnce清单签名”前面的勾去掉,然后重新生成解决方案。
第二种办法:
用记事本打开csproj文件,将文件中的" <SignManifests>true</SignManifests> " 改为 "<SignManifests>false</SignManifests>"。
第三种办法:用记事本打开项目的.csproj文件,删除类似以下xml就能顺利通过编译了
<ManifestCertificateThumbprint>B531F2CF222748C5E29308FC2247704827D1EA8C</ManifestCertificateThumbprint>
<ManifestKeyFile>xxxx_TemporaryKey.pfx</ManifestKeyFile>
<GenerateManifests>true</GenerateManifests>
<SignManifests>true</SignManifests>
<PublishUrl>D:/xxx/bin/</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<CreateWebPageOnPublish>false</CreateWebPageOnPublish>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<BootstrapperEnabled>true</BootstrapperEnabled>
声明:本文部分内容来源于网络,但由于作者疏忽,忘记保留资料来源的网址,请资料提供者原谅,如有侵权,请告知作者。