Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again. - InfoPath Dev
in

InfoPath Dev

Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

Last post 02-10-2011 09:29 AM by Hilary Stoupa. 18 replies.
Page 1 of 2 (19 items) 1 2 Next >
Sort Posts: Previous Next
  • 02-09-2011 11:35 AM

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I am attempting to submit to a SharePoint list using the instructions here:
    http://www.infopathdev.com/files/folders/qrules/entry61475.aspx

     When I click the "Submit to SharePoint List" button on page 10, I get this error:
    Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I do have a checkbox, but its values are set to 1 and 0 in the checkbox properties.  I also have two other "yes/no" questions, but they are set to text.  I've even tried removing all these fields from the form and I'm still getting the error.

     Can someone help? 

     Thanks!

     

  • 02-09-2011 11:56 AM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Hi, Carolyn:

    What are the data types of the fields in your SharePoint list?

    Hilary Stoupa

  • 02-09-2011 12:06 PM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    They're set to "number" with 0 decimal places.

  • 02-09-2011 12:12 PM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Can you attach the XML you are trying to submit? Under the Options tab, you can attach a file...

    Hilary Stoupa

  • 02-09-2011 01:42 PM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I'll email it to you privately.

  • 02-09-2011 02:12 PM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Just updating our thread here with the latest -- the attachments field should not be mapped. The attachments column in the list is actually a true / false value. With that column mapped to a field that had an attachment in it, you were submitting text to a true / false field (just like the error said).

    Here's a link to a doc that has more info on how to include attachments with your list items.

    Hilary Stoupa

  • 02-09-2011 02:20 PM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Thank you Hilary!  I'll read the document to get the attachment to work.

  • 02-09-2011 02:29 PM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    You should also be able to change your SharePoint list columns back to True / False, and form data types -- you seem to completely understand the way they need to match. What was tripping you up was just that Attachment field.

    It is true / false, and lets SharePoint know whether to display the little paperclip icon for the list item. The attachment itself has its own location. :-}

    Hilary Stoupa

  • 02-09-2011 04:47 PM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I can't get the attachment part to work.  There is no error message, it just doesn't attach.

  • 02-09-2011 04:50 PM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    What is your full command? I'm thinking you are using the version where you include the attachment with your SubmitToSharePoint list command?

    Hilary Stoupa

  • 02-10-2011 08:14 AM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Yes, I'm using one button to submit to list.  I'm using the instructions in the document, "qRules and Sharepoint-related commands."  I am up to step 16, but nothing is working yet.  Here's what the button says: 

    SubmitToSharePointList /submit=ShPSubmit /mapping=mapping /id=my:ID /dsname=AddAttachment /xpath=my:attachments/my:attachmentFile /uniqueName=yes

    Am I to understand that there needs to be a separate button to update the existing info in the list, and one to attach an attachmen to an existing list item?

    Thanks!

  • 02-10-2011 08:32 AM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I'm looking at the copy of your template you sent me, and the /xpath to your attachment file looks incorrect in your command. Wouldn't it be: /xpath=my:EEAP_Attachment ?

    EDIT: Sorry, I didn't really answer your question -- no, you don't need a separate button, the command you are using should submit to the list and save your attachment -- the issue is simply that your xpath is incorrect, I think.

    Hilary Stoupa

  • 02-10-2011 08:44 AM In reply to

    • Carolyn2
    • Top 500 Contributor
      Female
    • Joined on 07-15-2010
    • Redmond, WA
    • Posts 35

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    I changed the name of the field to match the existing field in SharePoint in the hopes that that would fix the problem
  • 02-10-2011 08:46 AM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    What is the full XPath to the attachment field in your form?

    Hilary Stoupa

  • 02-10-2011 08:57 AM In reply to

    Re: Errors occured submitting to list: Invalid Yes/No value A Yes/No field contains invalid data. It should be either 1 or 0. Please check the value and try again.

    Okay, got your latest template. Your command should be:

    SubmitToSharePointList /submit=ShPSubmit /mapping=mapping /id=my:ID /dsname=AddAttachment /xpath=my:Attachments /uniqueName=yes

    The /xpath needs to be to your attachment field in your form. The name of the field is immaterial -- but the xpath needs to be correct, and if you are working with a repeating group, relative.

    Hilary Stoupa

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