This is a migrated thread and some comments may be shown as answers.

How to control resource order

6 Answers 145 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Rob Diamant
Top achievements
Rank 1
Rob Diamant asked on 18 Feb 2009, 02:20 PM
Does anyone have a suggestion on how to control the order of the grouped resources. Right now it is displaying in alpha order (Alex, Bob, Dave, etc) but I want to move Sam to be the first one.

Thanks
Rob

6 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 19 Feb 2009, 01:00 PM
Hello Rob,

RadScheduler does not provide conrol for the resource ordering.

Best wishes,
Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Rob Diamant
Top achievements
Rank 1
answered on 19 Feb 2009, 03:20 PM
From some of my experimenting, it looks like the display order is driven off of the Resource record order. If I set or change the sort on the data source, it seems to control the display order. Can you confirm this. If so, I just need to come up with a creative way of resorting the data as needed.
0
Peter
Telerik team
answered on 19 Feb 2009, 04:01 PM

Yes, the resource order depends on the data source, so that's the way to control ordering of resources.


Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Anatolij
Top achievements
Rank 1
answered on 22 Feb 2009, 02:14 PM

What if the reources have numerical prefix in their name or alphabetic prefix in their name. Could that be used to order the staff in the particular order?

 

Regards

0
Peter
Telerik team
answered on 25 Feb 2009, 09:19 AM
Hello Anatolij,

If you are working with SQL you can simply use ORDER BY in your resource datasource. For example, the following will display the users in alphabetical order:

   <ResourceTypes> 
            <telerik:ResourceType DataSourceID="SqlDataSource2" ForeignKeyField="UserID"   
                KeyField="ID" Name="User" TextField="UserName" /> 
        </ResourceTypes> 
    </telerik:RadScheduler>    
    <asp:SqlDataSource ID="SqlDataSource2" runat="server"   
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>"   
        SelectCommand="SELECT * FROM [Users] ORDER BY [UserName]"></asp:SqlDataSource> 

For other types of data source you can resort to Implementing A Provider.


Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Rob Diamant
Top achievements
Rank 1
answered on 06 Mar 2009, 03:57 AM
Found the answer. If I add each resource via code in the order I want, the grouping maintains the order.

Thanks for the effort.

Rob
Tags
Scheduler
Asked by
Rob Diamant
Top achievements
Rank 1
Answers by
Peter
Telerik team
Rob Diamant
Top achievements
Rank 1
Anatolij
Top achievements
Rank 1
Share this question
or