The configuration sections in web.config support long lines, but the line must be a single line of text so that they can fit into the attribute:
<add name="" value="... some very long text can go in here..." />
A string also cannot contain quotation marks or line breaks or other XML markup characters. The data is primarily XML and must be properly encoded.
For example, if you have XML:
<root> <value>10</value> </root>
it should be saved in a configuration value such as this:
<add key="Value" value="<root>
 <value>10</value>
</root>" />
Which type wins the assignment of a configuration item.
Perhaps you better save the configuration value in a separate file in the file system and read it from there to a string or XmlDocument, etc.
source share