C#读取resx资源文件

 // Create a ResXResourceReader for the file items.resx.
            ResXResourceReader rsxr = new ResXResourceReader("D://练习//report//report//all.resx");

            // Create an IDictionaryEnumerator to iterate through the resources.
            IDictionaryEnumerator id = rsxr.GetEnumerator();
            Image i;
            // Iterate through the resources and display the contents to the console.
            foreach (DictionaryEntry d in rsxr)
            {
                MessageBox .Show (d.Key.ToString() + ":/t" + d.Value.ToString());
                i = (Image)d.Value;
                i.Save("c://aa.jpg");               
            }         
        
            //Close the reader.
            rsxr.Close(); 

你可能感兴趣的:(c,image,File,C#,resources)