When working with web services based on WCF you may get following or similar error after importing of references:
{System.Xml.XmlException: 'Element' is an invalid XmlNodeType. Line 8, position 26.
at System.Xml.XmlReader.ReadEndElement()
at System.Configuration.ConfigurationElement.ReadEmptyElement(XmlReader reader)
at System.ServiceModel.Configuration.BasicHttpSecurityElement.ReadXml(XmlReader reader)
at System.ServiceModel.Configuration.BasicHttpBindingElement.ReadXml(XmlReader reader)
at System.ServiceModel.Configuration.BasicHttpBinding
The problem is caused by element
<transport>
<extendedProtectionPolicy policyEnforcement="Never" />
</transport>
At this point of time it is sure that this happen on Windows7 BETA one and there is no an official workaround. To make it working remove this attribute after importing of references.
More about this attribute you can find here.
Posted
Jun 10 2009, 11:59 AM
by
Damir Dobric