我已经阅读了Resource文件上的所有文章,但大多数都在谈论获取字符串。我在名为myRes.resx的resx文件中有两个二进制文件。如何收回它们并将其保存到磁盘?
<resheader name="resmimetype"><value>text/microsoft-resx</value></resheader><resheader name="version"><value>1.3</value></resheader><resheader name="reader"><value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b99a5c561934e000</value></resheader><resheader name="writer"><value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b99a5c561934e000</value></resheader><data name="7zip.dll" type="System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b99a5c561934e000"><value>
TVqQAAMAAAAEAAAA//8AALgAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
gAAAAA4fug4AtAnNIbgBTM0hVGhpcyBwcm9ncmFtIGNhbm5vdCBiZSBydW4gaW4gRE9TIG1vZGUuDQ0K
JAAAAAAAAABQRQAATAEDALtch0YAAAAAAAAAAOAADiELAQYAANAAAAAgAAAAAAAA7ugAAAAgAAAAAAEA
......
</value>
rm = new ResourceManager("MyTestApp.myRes.resources", Assembly.GetExecutingAssembly());
byte[] array = null;
array = (byte[])rm.GetObject("7zip.dll"); //error