I want to store configuration information about my DLL in an XML file inside my DLL i.e. if changes need to be made the DLL must be re-compiled.
The reason is because its a elegant format and I may not use config files for this DLL.
Any ideas? I literally want to be able to edit an xml in Visual Studio then compile it and only see a DLL in the output.
Yup – include it as an Embedded Resource (i.e. use that setting in the Properties for the item in Visual Studio), then use
Assembly.GetManifestResourceStreamto read it.I do this all the time for unit test data. As you say, you can just edit the file, rebuild, and it’ll be there.