Using QRule to Keep our library fourm and list in sync - InfoPath Dev
in

InfoPath Dev

Using QRule to Keep our library fourm and list in sync

Last post 02-27-2012 08:38 AM by Hilary Stoupa. 20 replies.
Page 1 of 2 (21 items) 1 2 Next >
Sort Posts: Previous Next
  • 02-22-2012 11:02 AM

    Using QRule to Keep our library fourm and list in sync

    Hello QRules Experts,  I have been working on a SharePoint project for a few weeks now and ran into the issue where I needed to create a SharePoint list, then a InfoPath forum library to pretty up the users interface.  I am using SharePoint 2010 using Info path 2010. I created a 2010 SharePoint list that populates data from Our ERP system.  -Works fineThen I created a SharePoint Library Forum using Info Path 2010 that grabs some data from my erp and from List I created  - works great After looking on the internet SharePoint will not write back to the List out of the box without some custom code or limited workflow, so I came across QRules

    I downloaded the Trial, Installed, and followed the setup to write back to my list.  But when I click my update list button nothing happen i get no error and my list dose not get updated. I am not really sure how to trouble shoot this with no error message.  I followed the video to the tee @ http://www.qdabra.com/en/products/qRules_overview.aspx  (Synchronize Forms with SharePoint Lists)

    But sure if thers a wat to debug. 

    I am ready to purchase qRules   I can’t wait to add other features like Delete row from a repeating table using QRules. But i need to make sure this is going to do what i need before i do. 

     

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 12:18 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    So - what's the command you are using? You've put the QdabraRules error node on your form? And no information is returned when you run your command? You can always attach your form template here (under the options tab) and I'm happy to take a quick look.

    Hilary Stoupa

  • 02-22-2012 12:57 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    I am using the updatesharepointlist command .. I have not put the QdabraRules error node  not sure how. 

     

    I have attached the file

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 01:22 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    The Error node is in the Qdabra Rules data source. I've put it on your form for you to help you troubleshoot. Save the template locally, right click and select Design to open in IP in design mode.

    Your command is:

    SubmitToSharePointList /Submit=updatelistSubmit /mapping=mapping /id=myid

    But I don't see a node in your form named "myid" - and I'd expect to see the full path since none of your data is repeating, like perhaps:

    SubmitToSharePointList /Submit=updatelistSubmit /mapping=mapping /id=/my:myFields/my:field8

    So, I'm pretty sure the error you'd be getting in the error node would be about the /id parameter being incorrect.

    Hilary Stoupa

  • 02-22-2012 01:55 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

     This is the Error I Got

    Required parameter unspecified: submit. Usage is: SubmitToSharePointList /submit=Sharepoint List Service Submit Adapter Name /mapping=Mapping Adapter Name [/id=Path to Id field for SharePoint List Id (required if adding attachments)][/dsname=Data Source For AddAttachment Method (SharePoint Lists Web Service)][/xpath=XPath to attachment field][/name=Name for file (extension will be added by qRules)][/uniqueName=Prepend date and time information to the file name to provide a unique name (yes | no)]

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 02:20 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Sorry - should have caught that - your "submit" parameter is using upper case:

    /Submit=updatelistSubmit

    Try with lower case:

    /submit=updatelistSubmit

    Hilary Stoupa

  • 02-22-2012 03:20 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Ok so I fixed the submit and removed the id=myid  in the video it said it was optional.  after doing so I dont receive an error (great!)  But the lines dont get updated. when I look at the list it seems to add blank lines with no data not even what i entered on the form.  

    Am i to asume that snice i am going to be working with exsiting data in the list that i have to get the id working?

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 03:32 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    If you are going to work with existing list data, you'll need the /id parameter. That will need to be the full path to the field in your form's data source (as in my example above).

    Then you'll need to set that field to the ID for the item you wish to update in your list.

    However, it appears you selected that your data is from a repeating group when mapping - although your main data source is not repeating. In that case, you may need to use the relative path to the field you wish to use for the ID - /id=my:field8 for example.

    Usually when I see blank items submitted to the list it is because the form is executing the Submit data connection rather than letting qRules handle it. I don't see that happening in your form - in fact, aside from the mapping issue, it looks to be set up correctly.

    Did you fill out main data source fields that were mapped prior to submitting? I see you have a repeating table bound to a secondary data source on your form - qRules won't submit secondary data to a SharePoint list at this time - you'd need to copy the data into your main data source first.

    Hilary Stoupa

  • 02-22-2012 04:01 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

     Did you fill out main data source fields that were mapped prior to submitting? I see you have a repeating table bound to a secondary data source on your form - qRules won't submit secondary data to a SharePoint list at this time - you'd need to copy the data into your main data source first. Ok i am going to try and tackle this first. 

     

    Yes you are right I created a secondary data source linked to my SharePoint list then added it to a repeating section that will only display the lines from the list that correlate to the sales order number,up top.

    If I understand you correctly I can’t do this? How do I pull in the list info in to the form if I can’t use a data source?  

     

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 04:08 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Well, again, just guessing here based on your questions and what I've seen in your form....

    If you want to use your form to work with existing list items, the first step is getting those list items in to your main data source. Since your main data source appears to have no repeating nodes, you'll need to add a repeating group. For simplicity's sake, I'd structure it the same as your 2DS with your existing ShP info.

    Then, you could use qRules to copy your list data into your main data source using CopyTable - it is a pretty simple command to use.

    From there, you could edit and submit items in your form. If you don't want to save that data in your main data source, you could use the delete command to remove it when the user submits. Then when you want to load it again, you could pull it from the list and copy it back into your main data source.

    Of course, if you change your main data source, you'd need to re-do your mapping (which I know is kind of a pain - sorry about that....)

    Hilary Stoupa

  • 02-22-2012 05:09 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    First I want to apologize for taking up allot of your time I really appreciate it. I have been working on this project for a few weeks now and qRules seem to be my best option.   I attached a picture with some data to give you a better understanding of what I want to achieve.  The form comes up blank and you choose a sales order number from the drop down which auto fills all the form data from an ERP database and looks at the SharePoint list (list was auto populated before hand with SO# and Item) to give me the item numbers on the list that correlate to that sales order number the rest of the fields will be inputted by different departments as the process moves down.  If I understand you right I need to delete my current 2nd data source repeating table and create a repeating table in main, then redo my xml and links and so on but can I have qRues only pull the line that correlate with the same sales order number once the sales order has been chosen?

     


    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-22-2012 05:39 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Let me try again, I'm not doing a very clear job of explaining myself today.

    You can keep your current 2ds connection, you'll need that. But instead of displaying the table bound to the 2ds on your form, you'll need to copy the data from the secondary data source into the main data source of your form (here's a sample form, or check the sample form that came with qRules). So that means you need to add to the main data source for your form.

    When they select the sales order, you'd copy in the 2ds data to your main data source. You'll have mapped your main data source to the ShP list in the mapping tool. That's the data you'll be submitting.

    I'll try to find a little time to work up a quick sample for you before the weekend, okay? I think you'll understand just fine if I show it to you, I just think it is kind of complex and I'm not explaining it well. :-)

    Hilary Stoupa

  • 02-22-2012 05:57 PM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Hey, I took a quick stab at this with your existing form - I added a button that (in theory) should copy your 2ds into the main, just the ones with the matching SO number. Since I can't access your data sources, I'm unable to preview and actually trouble-shoot, of course. I also manually modified your mapping to point to the new main data source repeating group I created & changed your submit command to the new field for the id. Hopefully this will help.

    Hilary Stoupa

  • 02-23-2012 07:17 AM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    Mornig Hilary, well it will be for you when you read this I'll be eating lunch.

    So after a good night sleep this is what have

    1. I need to have my 2ds to pull data from my SPlist
    2. Since i want to use existing data and write back I need to move the data from my 2DS to a repeating table on my main DS (because qRules won't submit secondary data to a SharePoint list only from main)
    3. Once the data has been copied to main it will be liked via ID and I can edit and add info as I please.  When I submit it will update the list with the info and I can have it delete off the main upon save or close of the form
    4. When I reopen the form it will repull the info from my list already updated and i can repeat these steps as many times as I want

    This will work great I believe it will be a great start to my form

     

     

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

  • 02-23-2012 07:23 AM In reply to

    Re: Using QRule to Keep our library fourm and list in sync

    I downloaded and ran the form you sent me. All I get in error is (Failed to select the source row to copy from)

    Here is the formula used

    concat("CopyTable /dsnamesrc=Clearmarkinfo /tablesrc=/dfs:myFields/dfs:dataFields /rowsrc=ns1:SharePointListItem_RW[ns1:sonuumber='", sonumber, "'] /tabledest=/my:myFields/my:Items /rowdest=my:Item /empty=yes")

     

    Do i have to re-run the xml before hand?

    Gabriel Lebron
    Network Admin

    [email protected]

    Integra Companies, Inc.
    29 Saratoga Blvd
    Devens MA 01434
    www.integracompanies.com

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