2

Hey guys I was wondering how I could use foreach on a few specified resources...

for example, if i had these four resources, how could I cycle through the same action on each resource using foreach:

test.Properties.Resources.file1
test.Properties.Resources.file2
test.Properties.Resources.file3
test.Properties.Resources.file4
L.Mucker
  • 37
  • 5
  • 1
    Welcome. Your question is essentially a set of requirements. [ask] –  Aug 28 '17 at 04:22

1 Answers1

4

Try something like this

    ResourceSet resourceSet = Properties.Resources.ResourceManager.GetResourceSet(CultureInfo.CurrentUICulture, true, true);
      foreach (DictionaryEntry entry in resourceSet)
        {
            string resourceKey = entry.Key.ToString();
            object resource = entry.Value;
        }
GameR
  • 53
  • 5