Loop through all Resources in ResourceManager - C#

前端 未结 2 459
予麋鹿
予麋鹿 2020-12-03 20:51

How do I loop into all the resources in the resourcemanager?

Ie: foreach (string resource in ResourceManager) //Do something with the recource.

Thanks

2条回答
  •  眼角桃花
    2020-12-03 21:30

    I wonder why would you like to loop through all of the resources.

    Anyway, ResourceManager needs to be instantiated giving it a Type or the base name where to lookup for resources. Then you will be able to retrieve a ResourceSet but for a given CultureInfo, ergo if you want to obtain all the resources for a given `ResourceManager

提交回复
热议问题