Сортирање Календар Теми во Календарот Види

I’m using a calendar to track panel discussions on a given day. I have two sessions: morning and afternoon. I want to create a view that shows morning sessions only listed alphabetically via a session ID. This is a little tricky to accomplish (освен ако сум пропуштил нешто реално очигледен).

I can easily create a filtered view showing just that day’s events. The calendar will show all those events and if they all take place on the same hour, it lists them side by side in the hour slot. That’s great. The tricky part is that, од стандардните, it wants to list them in ID format. Така, if I add "Session 02" and then "Session 01" на календар, таа ги покажува по тој редослед (i.e, Сесија 02 а потоа сесија 01). To list them in Session ID order, Мислев да се обиде овие работи:

  1. Configure the view using the web user interface. No luck. There are no options to sort items this way.

    Од тоа не работа, I am now hoping there’s a CAML query somewhere in there that will allow me to override the sort. CQWP lets me make that kind of change, maybe calendar will as well?

  2. Edit the web part, look for an "export" function and … BZZZT! I can’t export its XML. There is no export option.

    I’m still holding out hope that I can find and modify some CAML query. Since I can’t export the web part, that leaves SharePoint Designer.

  3. I add the calendar web part to a sandbox site and open that site using SharePoint Designer. I look at the markup for the web part and I find what I’m looking for. It’s encoded madness, but it’s there: "<ListViewXml …. >encoded madness</ListViewXml>". Специјално, има овој скапоцен камен:

<Пребарување>
<Каде>
<DateRangesOverlap>
<FieldRef Name="EventDate"/>
<FieldRef Name="EndDate"/>
<FieldRef Name="RecurrenceID"/>
<Value Type="DateTime">
<Месец />
</Вредност>
</DateRangesOverlap>
</Каде>
<Orderby><FieldRef Name="Session_x0020_ID" /></Orderby>
</Пребарување>

(Сум декодира на &lt;Додади и &GT и им подели надвор на повеќе линии за доброто на јасност на).

Додадете <Orderby> малку и сега видови на сесија проект, не внатрешната елемент во листата проект.

Елена врвот o’ на капа, да се Becky Isserman за нејзиниот коментар на блог пост Иша Sagi е: http://www.sharepoint-tips.com/2008/07/caml-sorting-by-file-name.html. I wouldn’t have put the <Orderby> на право место без неа коментар.

Се надевам дека ќе ја напишам оваа до појасно со екран снимки наскоро, но во случај никогаш не го правам, барем јас го направи ова многу.

</крајот>

Technorati Тагови: , , ,

2 размислувања за "Сортирање Календар Теми во Календарот Види

  1. L Hibbs

    Thanks for the info. It works like a charm. I did a similar trick on a multi-field sort (3 полиња). The only issue with editing the CAML is that if the view is modified, the changes are overwritten. But that is life!

    Thanks for posting!

  2. Harsh

    I had put the tag after . But still it is not applying sorting on my Calendar. Also if I provide ant name in FieldRef value then also it does not throw any error. For e.g. test123 column does not exists in my calendar but if I try to use this field then also the page doesnot throw any error. I am not sure whether the tag is working. I am using SharePoint 2010.

Остави Одговори на Harsh Откажи одговор

Вашата е-маил адреса нема да бидат објавени. Задолжителни полиња се означени *