473,385 Members | 1,630 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

DataGrid Sort icon

Hello,

How can I force the sorting icon to apear in the header when the datagrid
first shows (before clicking any column header).

Thanks.
Nov 20 '05 #1
3 1154
ironically I just did this..

Dim cm as currencymanager

cm = BindingContext(myDataGrid.DataSource, myDataGrid.DataMember)

ctype(cm.List, DataView).Sort = "mySortColumn"

cm = nothing
-CJ

"Carlos Moreira" <ca****@cpi.pt> wrote in message
news:40**********************@news.telepac.pt...
Hello,

How can I force the sorting icon to apear in the header when the datagrid
first shows (before clicking any column header).

Thanks.

Nov 20 '05 #2
Whow !!!!

Great answer, thanks

"CJ Taylor" <[cege] at [tavayn] dit commmmm> wrote in message
news:Oa*************@TK2MSFTNGP11.phx.gbl...
ironically I just did this..

Dim cm as currencymanager

cm = BindingContext(myDataGrid.DataSource, myDataGrid.DataMember)

ctype(cm.List, DataView).Sort = "mySortColumn"

cm = nothing
-CJ

"Carlos Moreira" <ca****@cpi.pt> wrote in message
news:40**********************@news.telepac.pt...
Hello,

How can I force the sorting icon to apear in the header when the datagrid first shows (before clicking any column header).

Thanks.


Nov 20 '05 #3
Isn't programming fun? =)
"Carlos Moreira" <ca****@cpi.pt> wrote in message
news:40**********************@news.telepac.pt...
Whow !!!!

Great answer, thanks

"CJ Taylor" <[cege] at [tavayn] dit commmmm> wrote in message
news:Oa*************@TK2MSFTNGP11.phx.gbl...
ironically I just did this..

Dim cm as currencymanager

cm = BindingContext(myDataGrid.DataSource, myDataGrid.DataMember)

ctype(cm.List, DataView).Sort = "mySortColumn"

cm = nothing
-CJ

"Carlos Moreira" <ca****@cpi.pt> wrote in message
news:40**********************@news.telepac.pt...
Hello,

How can I force the sorting icon to apear in the header when the datagrid first shows (before clicking any column header).

Thanks.



Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: CGuy | last post by:
Hi, I have a datagrid that supports bi-directional sorting - i would like an icon (like an up or down arrow depending on the sort order) to be displayed in the datagrid column headers which...
2
by: enak | last post by:
I can not get my datagrid to page. I have a datagrid that I can sort 2 of the columns. This works great. I added paging and when I display the dg it shows 5 pages. (I am showing page numbers at...
3
by: Engineerik | last post by:
The vb6 datagrid had a "button" property which I used to display a dropdown icon in a cell. I created a popup menu that would display the list of valid choices for that cell when the user clicked...
14
by: Brett Sinclair | last post by:
Hello everybody I'm still on the learning curve here...and from what I read, I created inherited datagrid class so I could have icons, combobox...etc in the columns of my datagrid. The grid...
0
by: Skylar Challand | last post by:
I'm using a lightly colored background in my datagrid header which mades the ^ sort icon almost invisible...is there a way to change the color of that icon?
4
by: Rich | last post by:
I fill a dataset like this: dim da As New SqlDataAdapter, ds As New Dataset, conn As New SqlConnection .... da.Fill(ds, "tbl1") datagrid1.DataSource = ds datagrid1.DataMember = "tbl1" When...
4
by: Pawel | last post by:
Hello I've a problem with DataGrid and Icon. Incons are in DataGrid's cells next to the other data. And now. When i cklick this icon i want to change icon without reload site. How to do this?...
0
by: Claire | last post by:
Hi, Visual Studio 2003 The application Im writing is skinned and therefore i need to be able to write my own code for manipulating and drawing headers for a data grid outside of the control. I...
3
by: aRTx | last post by:
I have try a couple of time but does not work for me My files everytime are sortet by NAME. I want to Sort my files by Date-desc. Can anyone help me to do it? The Script <? /* ORIGJINALI
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.