在低于10的Windows版本上安装ClickOnce应用程序时出错

时间:2016-06-27 17:08:22

标签: .net windows winforms clickonce culture

每次我测试在虚拟Windows 7,8或8.1上安装应用程序时,由于错误总是无法安装,但是当我的一个朋友在Windows 10上安装它时,它工作得很好。我不明白这是什么问题。

错误的主要部分是这一部分:

aa-DJ is an invalid culture identifier.

这对我来说完全没有意义,直到现在才出现这个问题。

这是完整的错误日志:

PLATFORM VERSION INFO
    Windows             : 6.1.7601.65536 (Win32NT)
    Common Language Runtime     : 4.0.30319.42000
    System.Deployment.dll       : 4.6.1055.0 built by: NETFXREL2
    clr.dll             : 4.6.1076.0 built by: NETFXREL3STAGE
    dfdll.dll           : 4.6.1055.0 built by: NETFXREL2
    dfshim.dll          : 4.0.41209.0 (Main.041209-0000)

SOURCES
    Deployment url          : file:///C:/Users/Jazzy/AppData/Local/Temp/Anime%20Yu-Gi-Oh%20Card%20Maker.application
    Application url         : file:///C:/Users/Jazzy/AppData/Local/Temp/Application%20Files/Anime%20Yu-Gi-Oh%20Card%20Maker_5_1_0_0/Anime%20Yu-Gi-Oh%20Card%20Maker.exe.manifest

IDENTITIES
    Deployment Identity     : Anime Yu-Gi-Oh Card Maker.application, Version=5.1.0.0, Culture=neutral, PublicKeyToken=a899559596d8a437, processorArchitecture=x86
    Application Identity        : Anime Yu-Gi-Oh Card Maker.exe, Version=5.1.0.0, Culture=neutral, PublicKeyToken=a899559596d8a437, processorArchitecture=x86, type=win32

APPLICATION SUMMARY
    * Installable application.
    * Trust url parameter is set.
ERROR SUMMARY
    Below is a summary of the errors, details of these errors are listed later in the log.
    * Activation of C:\Users\Jazzy\AppData\Local\Temp\Anime Yu-Gi-Oh Card Maker.application resulted in exception. Following failure messages were detected:
        + Culture is not supported.
Parameter name: name
aa-DJ is an invalid culture identifier.

COMPONENT STORE TRANSACTION FAILURE SUMMARY
    No transaction error was detected.

WARNINGS
    There were no warnings during this operation.

OPERATION PROGRESS STATUS
    * [20/06/2016 11:38:04 PM] : Activation of C:\Users\Jazzy\AppData\Local\Temp\Anime Yu-Gi-Oh Card Maker.application has started.
    * [20/06/2016 11:38:04 PM] : Processing of deployment manifest has successfully completed.
    * [20/06/2016 11:38:04 PM] : Installation of the application has started.
    * [20/06/2016 11:38:04 PM] : Processing of application manifest has successfully completed.
    * [20/06/2016 11:38:10 PM] : Found compatible runtime version 4.0.30319.
    * [20/06/2016 11:38:10 PM] : Request of trust and detection of platform is complete.

ERROR DETAILS
    Following errors were detected during this operation.
    * [20/06/2016 11:38:10 PM] System.Globalization.CultureNotFoundException
        - Culture is not supported.
Parameter name: name
aa-DJ is an invalid culture identifier.
        - Source: mscorlib
        - Stack trace:
            at System.Globalization.CultureInfo..ctor(String name, Boolean useUserOverride)
            at System.Deployment.Application.AssemblyMetaDataImport.ConstructAssemblyName(IntPtr asmMetaPtr, Char[] asmNameBuf, UInt32 asmNameLength, IntPtr pubKeyPtr, UInt32 pubKeyBytes, UInt32 flags)
            at System.Deployment.Application.AssemblyMetaDataImport.ImportIdentity()
            at System.Deployment.Application.AssemblyMetaDataImport.get_Name()
            at System.Deployment.Application.Manifest.AssemblyManifest.LoadFromCompLibAssembly(String filePath)
            at System.Deployment.Application.Manifest.AssemblyManifest.LoadFromInternalManifestFile(String filePath)
            at System.Deployment.Application.DownloadManager.ProcessDownloadedFile(Object sender, DownloadEventArgs e)
            at System.Deployment.Application.FileDownloader.DownloadModifiedEventHandler.Invoke(Object sender, DownloadEventArgs e)
            at System.Deployment.Application.FileDownloader.OnModified()
            at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next)
            at System.Deployment.Application.SystemNetDownloader.DownloadAllFiles()
            at System.Deployment.Application.FileDownloader.Download(SubscriptionState subState)
            at System.Deployment.Application.DownloadManager.DownloadDependencies(SubscriptionState subState, AssemblyManifest deployManifest, AssemblyManifest appManifest, Uri sourceUriBase, String targetDirectory, String group, IDownloadNotification notification, DownloadOptions options)
            at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
            at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
            at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
            at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)

COMPONENT STORE TRANSACTION DETAILS
    No transaction information is available.

1 个答案:

答案 0 :(得分:3)

aa-DJAfar语言和Djibouti位置的语言标识符。操作系统版本低于Windows 10Windows Server 2016 Technical Preview时不受支持。

您的项目中的aa-DJ文化中有一些本地化表单。要解决此问题,您可以检查任何表单下是否有.aa-DJ.Resx文件,将其删除。

有关支持的语言代码标识符的详细信息,请查看Windows Language Code Identifier (LCID) Reference