| Visual Basic (Declaration) | |
|---|---|
<ExtensionAttribute()> Public Overloads Shared Function ThenBy (Of TSource,TKey)( _ ByVal source As IEntityQuery(Of TSource), _ ByVal keySelector As Expression(Of Func(Of TSource,TKey)) _ ) As IEntityQuery(Of TSource)  | |
| Visual Basic (Usage) |  Copy Code | 
|---|---|
Dim source As IEntityQuery(Of TSource) Dim keySelector As Expression(Of Func(Of TSource,TKey)) Dim value As IEntityQuery(Of TSource) value = EntityQueryExtensions.ThenBy(Of TSource, TKey)(source, keySelector)  | |
| C# | |
|---|---|
[ExtensionAttribute()] public static IEntityQuery<TSource> ThenBy<TSource,TKey>( IEntityQuery<TSource> source, Expression<Func<TSource,TKey>> keySelector )  | |
| C++/CLI | |
|---|---|
[ExtensionAttribute()] public: static IEntityQuery<TSource^>^ ThenBygeneric<typename TSource> generic<typename TKey> ( IEntityQuery<TSource^>^ source, Expression<Func<TSource^,TKey^>^>^ keySelector )  | |
Parameters
- source
 - keySelector
 
Type Parameters
- TSource
 - TKey
 
| C# |  Copy Code | 
|---|---|
var mgr = new DomainModelEntityManager(); var query = mgr.Customers.OrderBy(c => c.Country).ThenBy(c => c.CompanyName); var results = query.Execute();  | |
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family