How can I limit builds to only support EN "Microsoft.Expression.Interactions.resources.dll", and avoid DE, KR, FR, ES, etc...?
Asked Answered
D

4

18

When I build my WPF Project, it creates several language folders, each containing "Microsoft.Expression.Interactions.resources.dll".

The weird thing is that I never created translations of my resource strings to other languages, and yet it still creates DE, KR, FR, ES folders. What I just need is EN.

How can I limit the localization to just EN?

Darrelldarrelle answered 7/12, 2011 at 5:5 Comment(1)
Duplicate? I asked it first 6 years ago, and the "Disable Dll Culture" question is 4 years ago. So tell "Disable Dll Culture" author that his question is a duplicate of this one instead.Darrelldarrelle
Y
0

I just deal with it like this. Go to the properties of your reference and do this:

Set "Copy local = false"

Save

Set "Copy local = true"

Save

and that's it.

Visual Studio 2010 doesn't initially put: True in the reference tag and setting "copy local" to false causes it to create the tag. Afterwards it will set it to true and false accordingly.

Yeorgi answered 8/4, 2019 at 5:35 Comment(0)
I
2

You're seeing those files because you're using the Blend SDK for .NET (either directly or through the Prism library). That SDK includes localized resources thus they get included in your build output.

Here's how you create a Silverlight build that targets a specific culture. It should work the same way for WPF. The jist of it is:

  1. Make a new configuration in your solution.
  2. Edit each project file to specify the SupportedCulture as "en" (note the casing).

If your solution is quite large this could be a lot of work. Honestly it doesn't harm anything to have this additional files in a WPF application -- they simply take up a little more disk space. You could also only archive and ship the en culture resources. Assuming you've defined your NeutralResourcesLanguage as en your the application will always be able to find its resources (they'll just be in English).

Improbity answered 7/12, 2011 at 15:11 Comment(1)
Thanks! I specified en;en-US just to sure :)Darrelldarrelle
C
1

@Mike-Post solution didn't work for me :( Maybe because VS2012. I added <SupportedCultures>en</SupportedCultures> but nothing changed and also there was a warning that it is invalid element.

But here is another solution: http://social.msdn.microsoft.com/Forums/vstudio/en-US/feb23879-660d-43d1-93ef-90a63eef70c6/how-can-i-remove-localization-information-from-my-wpf-project

just delete these folders (except en maybe) from Program Files (x86)\Microsoft SDKs\Expression\Blend\.NETFramework\v4.0\Libraries

Clareta answered 2/8, 2013 at 16:42 Comment(4)
I'm having this issue, did you ever figure it out (without having to delete the culture folders in the SDK's folder)?Cathay
@AlexReed if you don't need them, why you can't just delete them from the SDK folder? As I remember I didn't find better solution. Or I think you can delete them from you output folder via Post Build VS project event (or copy everything else to another folder).Clareta
Ah, that is annoying. Guess I'll just do the post build event. Don't really want to delete the files. Thanks.Cathay
Breaking an SDK's or toolkit installation is not the recommended way to remove localization resources from a project's build folder. As for <SupportedCulture>not working - you have a typo. You typed <SupportedCultures>Baziotes
Y
0

I just deal with it like this. Go to the properties of your reference and do this:

Set "Copy local = false"

Save

Set "Copy local = true"

Save

and that's it.

Visual Studio 2010 doesn't initially put: True in the reference tag and setting "copy local" to false causes it to create the tag. Afterwards it will set it to true and false accordingly.

Yeorgi answered 8/4, 2019 at 5:35 Comment(0)
O
-2

I had this same irritation of unneeded localized folders and resources.dll files in the Output folder. Removing the reference to Microsoft.Expression.Drawing solved it.

Of course, this meant that I cannot use anything in that library; I was using <draw:Arc> in a XAML file to draw an arc. I just found a different way to draw the arc.

Ondometer answered 16/1, 2014 at 17:37 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.