When a user uploads/creates a document into my document library, i need to be able to apply a metadata tag to the document either from the URL query string or from the value selected in some web-part that is also on the page.
Here is the full explanation: I want to build a web-part that reads from a list and presents a hierachical navigation tree, the bottom level nodes will map to terms in the term-store and will be links to document libraries. Multiple bottom level nodes can point to the same library. When a user clicks a bottom level node they are taken to the relevent library for that node, when they create/upload a document the appropriate metadata term (that they clicked on in the navigation tree) will be applied to the document (they can't then change it).
Does anyone have any ideas how this might be done? I thought of adding a query string to the URL but not sure how to then apply the term to the item.
I also thought of creating a custom field that would be applied to the content type of the documents being uploaded but i don't think that the code in the field would be able to 'reach' up onto the page to grab the selected value from the navigation control or get it from the URL either.
Finally i thought of an event receiver on the doc library, but again i'm not sure how to obtain the term that needs to be applied to the document,
Any help would be appreciated,
Thanks