I Guys,
I have a similar problem. I am trying to display all error validation messages onSubmit. The code I am using does kinda work, however, its giving me the namespace of the item instead of a field name or custom name.
for example instead of displaying:
"StatusDate cannot be blank"
its reads
"<my:StatusDate xmlns:my"http://schemas.microsoft.com/......"></my:StatusDate> Cannot be blank"
code I am using:
for (i=0; i < XDocument.Errors.Count; i++)
{
objError = XDocument.Errors.Item(i);
XDocument.UI.Alert("Error message: " + objError.Node.xml + " " + XDocument.Errors.Item(i).ShortErrorMessage);
}