How can I get a list of all embedded resources defined in my application?
问题 How to get a list of all files (e.g. images) embedded as resources or content programmatically? I tried ResourceDictionary res = Application.Current.Resources; But this does not return any files. 回答1: If the resources have build action Content then there is no way to enumerate them. You can only access them directly by name (so you would already have to know the names). For resources with build action Resource or Embedded Resource you can use Ivan's solution. The discussion to this similar