Unanswered Sharepoint and InfoPath form to add Multiple Parameters to different field using URL

  • Tuesday, July 24, 2012 5:36 PM
     
     

     

    Hey Guys,

    I have a question that I have been struggling with for the past 3 days. I need help with passing multiple field parameters in a form, find below screenshots as well as an explanation to everything I did step by step in order to understand my whole issue:

    1- I created a list called: Audit Request data base, the list was a previous template done by a collegue of mine, and I then customized the form in it using InfoPath 2010.

    2- After Completing that step, the form was ready and it was good to go. This data base is for internal use only, that is why I created a seperate form library and inserted a Web Part (Form- Info Path form) and then linked it to the data base form that I previously created. Now this new Form library is were the formed is now stored, and our clients have access to it without the ability to access our data base list.  Please find below the sample form

     

    3-Since now the form is located in its own form library, we want to have some fields prepopulated according to the Link (URL) I'm providing them with.  What I did so far is I added a webpart on this form library (Query string filter) and connected it to the form to populate the AUDIT field to whichever I want in the URL: bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE. As shown above. We decided to pre populate the fields to miminize the errors entered by our clients. In case you are wondering we have 4 different sites for our clients and we will be placing a link to the form on their website, for example:

     bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE1

     bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE2

     bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE3

     bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE4

    All these links will populate a different value in the AUDIT field according to the URL.

     

    This is basically what I did so far, now for my question and I'm sorry I know this is a long post but I think its better if we are on the same page.

    I am trying to populate the AUDIT field as done earlier AND populate the REQUEST FIELD.. However, sharepoint is not allowing me to connect multiple fields using the query string URL. What I idealy want is to give this link to my clients:  bla bla.. Audit%20Request/Forms/AllItems.aspx?Audit=EXAMPLE & Request= TEST..  I need that & Reques=TEST to populate the Audit Field and the Request field to what I want entered according to the URL!!

    Please help me with any possible solutions!!

    THANKS,

    JD

All Replies

  • Thursday, July 26, 2012 11:47 AM
    Moderator
     
     

    Hi,

    Thank you for your post.
    I'm trying to involve someone familiar with this topic to further look at this issue. There might be some time delay. Appreciate your patience.

    Thanks & Regards,
    Emir


    Emir Liu

    TechNet Community Support

  • Thursday, July 26, 2012 9:23 PM
     
     

    Hi JD,

    If I understand correctly, you would like to have various hyperlinks with input parameters containing different information for each.  The goal is for your client to be able to click on this hyperlink and have some fields in the form be pre-populated with the data contained in the input parameters.

    If you were planning on only having a few different hyperlinks, you could create various filled in forms (XML files) with this information pre populated.  You could then give hyperlinks to these different XML files.

    If you want the input parameters to have data that is constantly changing, you would need to go a different route.  Check out this article for passing input parameters into browser based InfoPath templates:

    http://blogs.msdn.com/b/infopath/archive/2007/02/26/passing-data-into-a-form-input-parameters.aspx

    However, it appears as though you are using WebParts, and wish to pass the parameter into the Document Library. I don't believe the above article will work like that, since the template location is hard coded in the Web Part.  Someone else may have an idea how to do it with a web part, though.

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
     
    Regards,
    Ian Kavanagh
    Microsoft Online Community Support

  • Friday, July 27, 2012 4:03 PM
     
     

    Please let me know as soon as possible!

  • Friday, July 27, 2012 4:05 PM
     
     
    I managed to figure that out with rules on infopath, so once the Audit name = to certain value, the rule on infopath says that I want the other tab to contain this.. That I fixed, noow I have another problem regarding privacy issue and confidentiality. I dont want my clients to be able to see my database and I just want to oiffer them a link that they click on and I would receive the data they entered. I tried to play around with the permissions, but since the form feeds into the database, it wont allow users with no contribute permissions to submit the form! WHat can I do???
  • Thursday, August 09, 2012 9:43 PM
     
     

    Hi JD,

    You don't want your clients to be able to see your database, you only want them to be able to submit data based on the hyperlink you sent them. Let me know if I have misunderstood anything.

    When creating the data connection to SQL, did you choose Windows Auth or SQL credentials? If you built the InfoPath template off a table in the database, they will be able to query and submit to that table. They would need to know what they are doing in order to obtain the contents of the table, but they will have access to whatever you give them permissions to.

    One option you might want to consider is to use a web service to query and submit data to your database. This way you have complete control over what is queried and what is submitted.

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

    Regards,
    Ian Kavanagh
    Microsoft Online Community Support