"Schema validation found non-data type errors" - a cause other than nil - InfoPath Dev
in

InfoPath Dev

"Schema validation found non-data type errors" - a cause other than nil

Last post 05-13-2014 04:33 AM by rai.shekhar.chandra. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 06-03-2008 05:23 PM

    "Schema validation found non-data type errors" - a cause other than nil

    I was trying to append rows to a table in code and kept getting the dread "Schema validation found non-data type errors" error. It wasn't the nil error and it wasn't caused by children being out of sequence. The main data source was somewhat complex:

    formFields
        groupField1
           ...
        groupField2
           ...
        groupField3 (repeating)
               field4
               field5
               groupField6 (repeating)
                      field7
                      field8
               groupField9
        groupField10
           ...

        I wanted to append rows to groupField6. Its Xpath was /formFields/groupField3/groupField6, so I built a groupField6 table row and tried to AppendChild to groupField3. Got the error, tried variations and got the same error. Finally noticed that the AppendChild description says “Creates a new child node at the end of the list of child nodes of the current node.” The current node was groupField3, but I was trying to AppendChild after groupField9 (the last child of groupField3). The solution is to insert a groupField6A before groupField6, move groupField6 under it, and use groupField6A as the current node. The same issue exists for appending children to groupField3; it needs to have a container group inserted above it. A simple but costly mistake, as most are.

    Chris
     

  • 12-03-2008 02:42 AM In reply to

    • Samson
    • Not Ranked
    • Joined on 12-03-2008
    • Posts 2

    Re: "Schema validation found non-data type errors" - a cause other than nil

    Thanks dude Your post helped me

  • 10-26-2010 09:24 AM In reply to

    Re: "Schema validation found non-data type errors" - a cause other than nil

    Great post!

    I had initially thought it would append the node despite the fact that they would be out of sequence and it will still work.

    I guess another fix to this is to make the repeating field the last child in the section because the order in the schema doesn't matter when you create the form visuals.

    Thanks again.

  • 02-21-2012 09:36 PM In reply to

    Re: "Schema validation found non-data type errors" - a cause other than nil

     Hi Chris,

     Thanks for writing this informative Post. I was just wondering why I am not able to append a child to the node. This post save me a lot of time.

     

    Thanks Once Again!!

  • 06-10-2013 01:49 PM In reply to

    Re: "Schema validation found non-data type errors" - a cause other than nil

    Not sure what I do wrong but am still getting that error
    Not the nil, the fields' order is correct, I have a container group as the current node

    I don't even know how to get help without showing my form and code

     

  • 05-13-2014 04:33 AM In reply to

    Re: "Schema validation found non-data type errors" - a cause other than nil

    http://walisystems.com/articles/SPS/dropdown2/sharepoint_list_data.htm 

    The source code from above link is running just fine. When I downloaded the code and run on server it runs fine and all values from list populates. But when I run it from my own solution it does not populate and gives this error.

    Microsoft.Office.InfoPath.Server.SolutionLifetime.SchemaValidationException: Schema validation found non-datatype errors.
       at Microsoft.Office.InfoPath.Server.SolutionLifetime.SchemaValidation.Validate(Document document, XPathNavigator subtreeToValidate, XmlOperation operation)
       at Microsoft.Office.InfoPath.Server.DocumentLifetime.XmlNotificationManager.DoSchemaValidation(XmlNodeChangedEventArgs e)
       at Microsoft.Office.InfoPath.Server.DocumentLifetime.XmlNotificationManager.NodeChangedHandler(Object sender, DomEventArgs e)
       at Microsoft.Office.InfoPath.Server.Xml.DomEvents.FireQueuedEvents()
       at Microsoft.Office.InfoPath.Server.Xml.DomEvents.AfterEventHandler(Object sender, XmlNodeChangedEventArgs e)
       at System.Xml.XmlDocument.AfterEvent(XmlNodeChangedEventArgs args)
       at System.Xml.XmlNode.AfterEvent(XmlNodeChangedEventArgs args)
       at System.Xml.XmlNode.InsertAfter(XmlNode newChild, XmlNode refChild)
       at System.Xml.DocumentXmlWriter.Close(WriteState currentState)
       at System.Xml.XmlWellFormedWriter.Close()
       at System.Xml.XPath.XPathNavigator.InsertAfter(XmlReader newSibling)
       at System.Xml.XPath.XPathNavigator.InsertAfter(XPathNavigator newSibling)
       at Microsoft.Office.InfoPath.Server.Xml.XPath.InfoPathXPathNavigator.InsertAfter(XPathNavigator newSibling)
       at Microsoft.Office.InfoPath.Server.Xml.XPath.XPathNavigatorHost.<>c__DisplayClass58.<InsertAfter>b__57()
       at Microsoft.Office.InfoPath.Server.DocumentLifetime.OMExceptionManager.ExecuteOMCallWithExceptions(OMCall d, ExceptionFilter exceptionFilter)
       at Microsoft.Office.InfoPath.Server.DocumentLifetime.OMSecurityContext.ExecuteOMCall(Solution solution, SecurityLevel methodSecurityLevel, ExceptionFilter exceptionFilter, OMCall d)
       at Microsoft.Office.InfoPath.Server.Xml.XPath.XPathNavigatorHost.InsertAfter(XPathNavigator newSibling)
       at testing1.FormCode.AddDepartment() in C:\Documents and Settings\chandrashekhar.rai\My Documents\InfoPath Projects\testing11\FormCode.cs:line 114

     

     

     

    Any help is appreciated.

Page 1 of 1 (6 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.