Sorting related documents by tag count or other..

Jon White asked on December 3, 2014 17:06

Hi there, me again!

I have a set of documents using "DocType A's" which are manually linked relationships to certain "DocType B's" using the 'related documents' field.

On the 'Doctype B's' pages I am using a repeater to show these selected related documents (A's). Which is fine and works.

However, the 'related document' list seems to just be ordered alphabetically, is there a way I can re-order the related document list using something else?

Ideally i'd like to use the tags from both document types and order by 'number of matching tags' so the most relevant goes to the top.

Can this by done, if so how?

Thank you in advance Jon

Recent Answers

Virgil Carroll answered on December 4, 2014 00:08

Are you trying to doing this via code or via the UI?

0 votesVote for this answer Mark as a Correct answer

Brenden Kehren answered on December 4, 2014 04:44

In your previous post about ordering the tags, I believe the answer was you'd need to have the source code to make this modification.

Regarding ordering by related document, if you are doing this via the API, you can simply take the results in a dataset and reorder them. I don't know of a way to do this with out of the box webparts. You could create your own webpart using the standard repeater and then perform your ordering within there using the API if you plan to use it more than one place.

Good luck!

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.