How do I send a field value of document library item to a survey list field?
Posted on 2011-02-25
Hi - I'm hoping someone out there can help me with a problem I'm trying to solve in SharePoint 2010. I’ve tried a few solutions I’ve found online that are similar to my issue but nothing quite works the way I want it to. Here’s my issue:
I have a site based on the Enterprise Wiki template and within that site I have a document library called "Pages".
Within my Pages library I have several help articles. Each article is using a custom Page Layout.
When a user is on an article page I have provided a link for them to submit feedback on the article to a survey list called “Article Feedback” also within the same site. **The submit feedback link is coded in the page layout, not the article page content
The submit feedback link opens a dialog box for the survey list's NewForm.aspx page.
I would like to collect the value of a field called “ID” for the current article in the Pages Document Library then send it via a query string to the NewForm.aspx page.
Once the NewForm.aspx page loads in the dialog box the ID value sent in the query string should be automatically set in a single line text field on the form and also be set to read only so the user can't change it.
Is there a way to get the value of the ID field and put it in a query string so when the user click the "Send Feedback" link from the article page the value is passed to the NewForm.aspx page?
Once I am able to pass the value to the NewForm.aspx page how do I populate the text field on my survey list with this value?
I’m fairly new to this so hopefully I’ve given enough information for someone to help with this. Thanks to all that take the time to reply.