views:

39

answers:

2

Is it possible to have strings in a .NET assembly that can be edited by some external tool? If it is, what tool?

For instance for a single-file Windows Forms application that can be installed simply by copying the single file (no installer required), and where a build system (or a manual process) configures the application on a per-client basis by changing/setting some strings before being distributed to the install location.

I know that this would normally be in a configuration file, but it is useful for simplicity of installation/configuration.

A: 

Have a look at .Net Satellite Assemblies and the role that they have in language / string customisation.

Satellite assemblies

Brian Scott
@Brian Scott: how can Satellite Assemblies be edited by an external tool?
Heidelbergensis
@Brian Scott: don't the use of Satellite Assemblies result in more than one file - one or more .resx files? Then I can just as well use configuration files.
Heidelbergensis
+4  A: 

Add a text file (or xml) as an embedded resource. Before compliling you can modify it's content to suit. You rapp can the access the file and read the values contained therein.

MaLio