Xamarin.forms Xamarin forms resx本地化始终返回默认语言
我的Xamarin forms resx本地化在visual studio更新后始终返回默认语言 当前版本是VisualStudio16.9.5,我尝试了16.10预览版,但它有相同的错误 My AppResources.resx文件设置Xamarin.forms Xamarin forms resx本地化始终返回默认语言,xamarin.forms,localization,resx,Xamarin.forms,Localization,Resx,我的Xamarin forms resx本地化在visual studio更新后始终返回默认语言 当前版本是VisualStudio16.9.5,我尝试了16.10预览版,但它有相同的错误 My AppResources.resx文件设置 Build action: Embedded Resource Custom tool: PublicResXFileCodeGenerator Build action: Embedded Resource 以及其他AppResources.ko.res
Build action: Embedded Resource
Custom tool: PublicResXFileCodeGenerator
Build action: Embedded Resource
以及其他AppResources.ko.resx和AppResources.ja.resx文件设置
Build action: Embedded Resource
Custom tool: PublicResXFileCodeGenerator
Build action: Embedded Resource
下面的变通方法已应用,但对我无效。
()
请帮帮我。。我花了将近两天的时间来研究这个问题
----------------------------------加---------------------------------------
我的主要项目名为“核心”
我的resx文件位于“Core/Properties/”(例如]Core/Properties/AppResources.resx')中
默认语言为'en',我还有'AppResources.ko.resx'和'AppResources.ja.resx'与AppResources.resx在同一路径中。我已经解决了这个问题 问题来自最新的visual studio版本和以前的解决方法() 前面的解决方案建议修改Android project.csproj文件,如下所示
<Target Name="_ResolveSatellitePaths"
DependsOnTargets="_ResolveAssemblies">
<ResolveAssemblyReference
AllowedAssemblyExtensions="$(AllowedReferenceAssemblyFileExtensions)"
AssemblyFiles="@(ResolvedUserAssemblies)"
AutoUnify="$(AutoUnifyAssemblyReferences)"
FindDependencies="True"
FindRelatedFiles="False"
FindSatellites="True"
SearchPaths="$(AssemblySearchPaths)"
TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
TargetFrameworkMonikerDisplayName="$(TargetFrameworkMonikerDisplayName)"
TargetFrameworkDirectories="$(TargetFrameworkDirectory)">
<Output TaskParameter="SatelliteFiles" ItemName="_AndroidResolvedSatellitePaths"/>
</ResolveAssemblyReference>
但是,在更新VisualStudio之后,这种变通方法产生了问题
我删除了这个代码,一切正常 尝试将
自定义工具:PublicResXFileCodeGenerator
更改为自定义工具:ResXFileCodeGenerator
@LeoZhu MSFT对我无效:(你能分享一个可以重现此问题的示例吗