Suppose you have an XElement or an XmlElment or even a string containing xml that you want to send via WCF. Are there any special precautions you have to take? The question just came up, what happens when, within the xml message, you transmit an xml document declaration (<?xml version=’1.0’ ?>), which may happen if serializing an XmlDocument...
+1
A:
I hade no problem sending XML as a string with WCF. If your XML exceed a few Kb, you must make changes in client&server to allow larger data amounts.
mliesen
2008-09-26 23:18:15
+2
A:
Just thought I'd add that in most cases these will be configuration changes, unless you're doing all your binding setup through code.
Specifically, you'll probably need to adjust the MaxReceivedMessageSize property of the binding and the reader quotas on the receiving side.
This is not related specifically to sending XML, by the way, it just comes up whenever you're sending largish messages because the default quotas are very conservative (64kb max message size, for example).
tomasr
2008-09-28 13:45:37
i just always add an additional zero. 640kb should be enough for anyone
Simon_Weaver
2009-12-15 00:35:13