.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Dundas Map - Legend sort order

Posted By:      Posted Date: September 10, 2010    Points: 0   Category :Sql Server
ello, We are using Dundas Maps together with Reporting Services 2008. Now we have come across a problem which we are not able to solve ourselves.   We produce a map showing each countries “ReportingFormat”. The SQL in the background  has the “order by ReportFormat” clause.   The values available in “ReportFormat” are shown in the legend. So far everything looks fine and the values within the legend are ordered correctly (E2B, Intdis, Not specified). See the picture http://img340.imageshack.us/i/correctorderfrompreview.jpg/   We therefore deploy the report and open it up in Internet Explorer but now the order of the legend has changed and is shown as (Intdis, Not specified, E2B). See the picture http://img816.imageshack.us/i/incorrectorderfromie.jpg/   We have tried to set the sorting also within the map (not only within the SQL) but the same problem remained although we are not sure we set that sorting correctly . We are not sure that we found the series collection where we could set the sort order. It is all a bit confusing when working with the maps.   As a final solution we tried to change the available values in “ReportFormat” but then the order was even more confusing. See table below; Available values (ReportFormat) Order in legend in Visual studio preview Order in legend in Internet

View Complete Post

More Related Resource Links

What is the meaning of Ascending\descending sort order of a column within an index

When I add a new index I can also specify the "sort order" as ascending or descending. What does it mean? does it affect performance? does it mean that the binary search tree will be set in a certain way?

Dynamic Data Entity Framework: Initial Sort Order for Views

Hello Steve,I'm trying to set an initial sort order for my View (not table) in Dynamic Data using Entity Framework 2. I have updated my Model and Imported the View. Now I'm trying to use the DisplayColumn attibutebut it's not working.[DisplayColumn("Product", "ParsingOrder", true)]Fabio

order by sort both select in union



I have DropDownList that Show all groups. in that, I want to show "select one group" as default in DDL. for that i used code below. but it sort all return data and "select one group" will not be the first line. How can i fix it?

Best Regards. Morteza


	SELECT   -1 as id,'select one group' as groupName
	SELECT   id, groupName
	FROM     [group] 
	order by groupNam

SSRS 2005 and Sort Order

I have a table and want to sort the 1st column which is called "WorkType" in a particular order. At present it looks like this.

Admin Tasks
Leave & Public Holiday

managed metadata sort order for swedish


Sort order for managed metadata is not as expected, for instance Swedish letters Å and Ä are sorted as A

The properties for the standard language is set to swedish and explicit sort order is not set.

Is this a bug, or are we doing something wrong?


Microsoft SharePoint Server 2010 (14.0.4763.1000)

Language Pack for SharePoint, Project Server and Office Web Apps 2010 - Swedish/svenska (14.0.4763.1000)

Persist sort order in datagrid



I've got multiple datagrids in the application I'm currently working on. Their ItemSource can be updated with new content on server notifications. When this happens, the ItemSource is being replaced by a new one (would it be better to update the content of the ItemSource - which is much more complicated for this case of figure - instead of binding a new one?)

When the new ItemSource is being bound, the sorting of the grid is being lost. I've solved this behaviour by saving the sorting before setting the new binding and restoring it after the new binding has been done. Below you'll find the static methods used for that:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Windows.Controls;
using System.Windows.Data;
using Telecontrol.SIPPR.Client.Commons.DataObjects;

namespace Telecontrol.SIPPR.Client.Commons.Utils
  public static class DataGridUtil

SharePoint 2010 library sort order is incorrect.


When sorting by name in a SharePoint 2010 library, numeric results are sorting incorrectly. For instance "122_Test" will sort in front of "13_Test". I know at one point years ago Windows Explorer had the same issue, but when viewing the same library by using the Open with Explorer option, Windows Explorer correctly displays the results. Has anyone encountered this issue, and if so have you found a fix?


Tim Vander Kooi

In RB 2.0 how to sort in ascending/descending order as default?

I have column say of Provider Type which I want to be ordered when report is run so that all other columns are ordered according to the order of the Provider Type values.

WPF: how to make a GridView only sort on one column as ascending order?


We use GridView inside the Listview. We need the grid view alwasy sort on one column ascending order and not allow to click column header to change it.

Is there a easy way to achieve it in Xaml?

If not possible, how to achieve it in code behind?



Datatable sort in a particular order


How do I sort a data table based on a particular column which has integer values in ascending order?


I wrote this:

leadtable.DefaultView.Sort = "Id"

But it doesnt seem to work, it displays fine but when i get try to get the values of the sorted datatable in an array they dont come in an sorted ordere

Datatble is defined as:


  • leadtable = New DataTable("LeadTable")   
  •         Dim leadid As New DataColumn("Id")   
  •         leadi
  • How can I use ORDER BY by passing different columns and sort orders?


    Hi all

    Here is what I am trying to do:

    declare @dateBegin as datetime, @dateEnd as datetime
    declare @column as varchar(30), @order as varchar(4)
    set @dateBegin = null
    set @dateEnd  = null
    set @column  = 'created'
    set @order   = 'DESC'
    	(@dateBegin is null or startTime >= @dateBegin) and (@dateEnd is null or endTime <= @dateEnd)

    list dropdown sort order


    i have a list in that i have a column called startdate (date field) which has dropdown values showing as ascending, descending, empty then it is showing all the dates in ascending order i want to show this in descending order in the dropdown , can you please help how can i get this done, please let me know if you don't understand i will explain further

    thanks in advance for the help

    How to sort GridView?

    In this article I will discuss how to sort columns in grid and more. At the end it will help answer some very frequently asked questions like following

    Sort by gridview SortExpression parameter via Stored Procedure


    I have a gridview that calls data via a stored procedure.  I am unable to enable the gridview columns to be sortable. I need to set the parameter in the Stored Procedure, can someone help me with this?

    Here is my gridview:

    <asp:GridView ID="AllUsersGrid" runat="server" AutoGenerateColumns="False" DataKeyNames="UserName"
                            GridLines="Vertical" Width="900px" DataSourceID="SqlDataSource1" AllowSorting="True"
                            SelectedRowStyle-Height="30px" CellPadding="4" BackColor="White">
                                <asp:TemplateField HeaderText="Full Name" SortExpression="lastname">
                                        <asp:Label ID="DisplayName" runat="server" Text='<%# Eval("firstname").ToString() & " " & Eval("lastname").ToString() %>' />
                                <asp:BoundField HeaderText="User Name" DataField="UserName" />

    Sorting ORDER BY - WORD


    Is it possible with SQL sorted in descending order according to the word?
    In Table I shrajeno Mastercard, Visa, Diners etc ...

    All Visa are the first in the order, another Mastercard, etc. ...

    Something does not work: ORDER BY PaymentType = 'Visa';

    I would not want to work in one field PaymentId (111,222,33, etc. ..) and then use the ORDER BY.

    Is this possible in such a way?

    Linq qry with order by basic questions


    I have never tried a group by with linq, now I do and I'm stuck.

    I try to convert this sql statement to its linq counterpart :

    SELECT COUNT(tb_Mailer_Smses.Id) AS [cnt], tb_Mailer_mailing.Id As [Id]
    ,SUM( CASE WHEN tb_Mailer_smses.DLRStatus = 200 THEN 1 ELSE 0 END) As [Delivered]
    ,SUM(CASE WHEN DLRStatus BETWEEN 300 AND 499 THEN 1 WHEN DLRStatus BETWEEN 800 AND 899 THEN 1 END) AS [Errors]
    FROM tb_Mailer_mailing INNER JOIN
    tb_Mailer_Smses ON tb_Mailer_mailing.Id = tb_Mailer_Smses.MailingId
    WHERE tb_Mailer_mailing.ApplicationId = 1
    GROUP BY tb_Mailer_mailing.Id

    Is there some one who can me show me the convertion process ?

    ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
    Sql Server  SharePoint  Silverlight  Others  All   

    Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend