Solved

How do I send a field value of document library item to a survey list field?

Posted on 2011-02-25
3
310 Views
Last Modified: 2012-05-11
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.
0
Comment
Question by:webgrl74
  • 2
3 Comments
 
LVL 6

Expert Comment

by:psv1973
ID: 34996384
Maybe a silly question, but why don't you use a workflow here? with sharePoint Designer 2010 you can create a workflow which could do all the steps that you describe in your post.

Simply create a new feedback workflow. During this process you can then update the original document when you need to.
0
 

Accepted Solution

by:
webgrl74 earned 0 total points
ID: 35165626
Thanks psv1973 for your response. I did consider using a workflow but my users only have read permissions on the list and they would need edit for that to work so it wasn't an option for me.

I ended up just capturing the url of the article page the user was on before clicking the feedback link and passing it in a query string. Once on the feedback form I used the "getTagFromIdentifierAndTitle" (javascript found on various sites across the Net) to assign the query string value to a text field on my feedback form.

Not as unique as the Document ID but the probability that the urls for my article pages will change after feedback is submitted is very rare so in this case it was an acceptable solution for me.

Thanks again for your help
0
 

Author Closing Comment

by:webgrl74
ID: 35196648
No acceptable solutions were provided before I managed to solve the issue myself.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When installing SharePoint 2010 RTM I came across a strange error, I was getting timeouts during the installation. I searched the web and found the best solution to be found here (http://social.msdn.microsoft.com/Forums/en-US/sharepoint2010genera…
SharePoint Designer 2010 has tools and commands to do everything that can be done with web parts in the browser, and then some – except uploading a web part straight into a page that is edited in SPD. So, can it be done? Scenario For a recent pr…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now