Hi, I'm about to start creating a new application that loads a project class containing various configuration parameters and descriptions,
Being this class something that has to be updated by the application and that will be modified in time adding new properties I wanted to use the XamPropertyGrid control to edit its contents.
The Property grid is ruled by attributes and this means that properties descriptions must be written in code and cannot be resources.
So I was wondering, is it possible to replace at runtime the property descriptions if I need to manage different cultures?
Elsewhere I need to use a different editor custom built.
thank you in advance
Sabrina
Here you go. The solution you have been waiting for :0)
http://brianlagunas.com/localize-property-names-descriptions-and-categories-for-the-xampropertygrid/
Let me know if this was helpful.
I actually tested it and got it working perfectly. I have the Description, DisplayName, and Category all localized with a simple attribute. I am writing a blog about it right now. I will post the link when I am done. Should be today.
I've read the article and it looks promising :o) I'll experiment on this, thank you for the tip.
I have used attributes to localize enum descriptions. Maybe you can use the same approach to keep your code clean and simple. I haven't tried it myself for the xamPropertyGrid, but it may be worth a look.
http://brianlagunas.com/localize-enum-descriptions-in-wpf/
Hello Sabrina,
I am just checking if you got this worked out or you still require any assistance or clarification on the matter.