ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   sort button,macro, or ? (https://www.excelbanter.com/excel-programming/338519-sort-button-macro.html)

tiffky

sort button,macro, or ?
 
Is it possible to program excel, or by any other means, to make a clickable
sort
button out of column headings so that I can quickly sort by date, address,
name, etc
without the multiple steps of highlighting all the cells then clicking data
- sort - and specify the column to sort by? This would be similar to how you
can sort in i tunes.
In i tunes the songs are listed by name, album, songwriter, date added, etc.
It is a breeze sorting your songs by any of the column titles just mentioned
because the column title cell is a button that is clickable and it sorts the
whole list with a click, keeping all information in each row together. If
someone who has worked with or is familiar with i tunes could respond that
would be great since you'd know exactly what I am talking about.

THanks!

Tom Ogilvy

sort button,macro, or ?
 
If you have Excel 2003, this is called a list and supports the functionality
you describe:

http://office.microsoft.com/en-us/as...129821033.aspx

for a quick overview:
http://office.microsoft.com/en-us/as...982731033.aspx
see the Heading "Excel List"

--
Regards,
Tom Ogilvy


"tiffky" wrote in message
...
Is it possible to program excel, or by any other means, to make a

clickable
sort
button out of column headings so that I can quickly sort by date, address,
name, etc
without the multiple steps of highlighting all the cells then clicking

data
- sort - and specify the column to sort by? This would be similar to how

you
can sort in i tunes.
In i tunes the songs are listed by name, album, songwriter, date added,

etc.
It is a breeze sorting your songs by any of the column titles just

mentioned
because the column title cell is a button that is clickable and it sorts

the
whole list with a click, keeping all information in each row together. If
someone who has worked with or is familiar with i tunes could respond that
would be great since you'd know exactly what I am talking about.

THanks!




Richard Buttrey

sort button,macro, or ?
 
On Sat, 27 Aug 2005 08:40:28 -0700, tiffky
wrote:

Is it possible to program excel, or by any other means, to make a clickable
sort
button out of column headings so that I can quickly sort by date, address,
name, etc
without the multiple steps of highlighting all the cells then clicking data
- sort - and specify the column to sort by? This would be similar to how you
can sort in i tunes.
In i tunes the songs are listed by name, album, songwriter, date added, etc.
It is a breeze sorting your songs by any of the column titles just mentioned
because the column title cell is a button that is clickable and it sorts the
whole list with a click, keeping all information in each row together. If
someone who has worked with or is familiar with i tunes could respond that
would be great since you'd know exactly what I am talking about.

THanks!


First give a name to your data, excluding the column headings - say
"Database"

Then name your column headings "Date", "Address", "Name"

Then add as many as buttons as you need to sort by. For example add
the first button and in the properties of the button, change the
Caption property to read "Date".

Then in the click event of the button add the following

Private Sub CommandButton1_Click()
Range("database").Sort key1:=Range("date")
End Sub

.....repeat as necessary with other buttons, changing the sort key1
name in the code as appropriate, i.e. "address", "Name" etc..


HTH

__
Richard Buttrey
Grappenhall, Cheshire, UK
__________________________

tiffky

sort button,macro, or ?
 
Thanks Tom and Richard!

"Tom Ogilvy" wrote:

If you have Excel 2003, this is called a list and supports the functionality
you describe:

http://office.microsoft.com/en-us/as...129821033.aspx

for a quick overview:
http://office.microsoft.com/en-us/as...982731033.aspx
see the Heading "Excel List"

--
Regards,
Tom Ogilvy


"tiffky" wrote in message
...
Is it possible to program excel, or by any other means, to make a

clickable
sort
button out of column headings so that I can quickly sort by date, address,
name, etc
without the multiple steps of highlighting all the cells then clicking

data
- sort - and specify the column to sort by? This would be similar to how

you
can sort in i tunes.
In i tunes the songs are listed by name, album, songwriter, date added,

etc.
It is a breeze sorting your songs by any of the column titles just

mentioned
because the column title cell is a button that is clickable and it sorts

the
whole list with a click, keeping all information in each row together. If
someone who has worked with or is familiar with i tunes could respond that
would be great since you'd know exactly what I am talking about.

THanks!






All times are GMT +1. The time now is 05:27 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com