Visual Basic Code , VB.NET Code, VB Code
  Home   :  Code   :  Forums   :  Submit   :  Mailing List   :  About   :  Contact
A1VBCode Forums
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      

Home » .NET Programming (VB 2010 or earlier) » Visual Basic .NET » VB.Net 2008 Sort DataGridViewTextBoxColumn...


VB.Net 2008 Sort DataGridViewTextBoxColumn...Expand / Collapse
Author
Message
Posted 1/27/2012 4:03:48 PM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 2/14/2012 12:01:09 AM
Posts: 12, Visits: 13

I’m using VB.Net 2008 application program.

 I’m using DataGridView, where column types DataGridViewTextBoxColumn. I have 3 fields. 1 field values are numeric, 1 field values are string and 1 field values are decimal.

 When I try to sort the string value column, it sorts correctly. But when i try to sort the numeric value column, it sorts as if its string value.

 I searched a lot to make it sort numerically. But I couldn’t find it.

 If you know how i can sort that column, please help me. If you can provide an example, that will be so helpful.

 Thanks in advance.

Post #31179
Posted 1/29/2012 8:08:11 AM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 2/14/2012 12:01:09 AM
Posts: 12, Visits: 13

while adding data to column, somehow i converted that to string. once i removed that, it's working fine and start sorting.

 

Post #31180
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 1 (1 guest, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Admin, Mod, Mark, Keithuk

PermissionsExpand / Collapse

All times are GMT -5:00, Time now is 3:24pm