#1   Report Post  
Posted to microsoft.public.excel.misc
thebottomline
 
Posts: n/a
Default Basic Sorting query


Hi, I'm very new to Microsoft Excel, and all I know is primarily self
taught, as in my course we focussed on the use of Microsoft Access
instead. Anyway, my query is as follows:

I've made a spreadsheet for the football world cup. I have one sheet
with the fixtures in, and one with the groups that take data from the
fixtures to make the group tables. My problem with the sorting is as
follows:

Because of the way the groups are done, I've got them sorted firstly by
points descendingly, secondly by goal difference, then thirdy by goals
scored. When I enter results for the fixtures in the first sheet, it
updates the table for results and points, but doesn't update the
sorting. I have to go Data - Sort and press OK again for it to Sort
again.

Is there any way to update Sort automatically?

Thanks for any help.


--
thebottomline
------------------------------------------------------------------------
thebottomline's Profile: http://www.excelforum.com/member.php...o&userid=35290
View this thread: http://www.excelforum.com/showthread...hreadid=550780

  #2   Report Post  
Posted to microsoft.public.excel.misc
somethinglikeant
 
Posts: n/a
Default Basic Sorting query

i'd link this to button, so that after you have enterred all your
scores you can update

Sub Reordertables()
Sheets("Sheet2").Activate
Selection.Sort Key1:=Range("G2"), Order1:=xlDescending,
Key2:=Range("F2") _
, Order2:=xlDescending, Header:=xlGuess, OrderCustom:=1,
MatchCase:= _
False, Orientation:=xlTopToBottom
End Sub

I assume you have more than one table though.
I'd say record a macro while you perform the task and see what code is
generated.

somethinglikeant


thebottomline wrote:
Hi, I'm very new to Microsoft Excel, and all I know is primarily self
taught, as in my course we focussed on the use of Microsoft Access
instead. Anyway, my query is as follows:

I've made a spreadsheet for the football world cup. I have one sheet
with the fixtures in, and one with the groups that take data from the
fixtures to make the group tables. My problem with the sorting is as
follows:

Because of the way the groups are done, I've got them sorted firstly by
points descendingly, secondly by goal difference, then thirdy by goals
scored. When I enter results for the fixtures in the first sheet, it
updates the table for results and points, but doesn't update the
sorting. I have to go Data - Sort and press OK again for it to Sort
again.

Is there any way to update Sort automatically?

Thanks for any help.


--
thebottomline
------------------------------------------------------------------------
thebottomline's Profile: http://www.excelforum.com/member.php...o&userid=35290
View this thread: http://www.excelforum.com/showthread...hreadid=550780


  #3   Report Post  
Posted to microsoft.public.excel.misc
mrice
 
Posts: n/a
Default Basic Sorting query


I would suggest using the record macro function to record the manual
sorting operation and then copy the code into the worksheet_activate
event macro for the second sheet.

This way, every time you switch to the second sheet, a sort will be
done automatically.


--
mrice

Research Scientist with many years of spreadsheet development experience
------------------------------------------------------------------------
mrice's Profile: http://www.excelforum.com/member.php...o&userid=10931
View this thread: http://www.excelforum.com/showthread...hreadid=550780

  #4   Report Post  
Posted to microsoft.public.excel.misc
thebottomline
 
Posts: n/a
Default Basic Sorting query


Cheers mrice, that sounds the best way to do it, everytime i go onto the
sheet it happens. how would i go about doing that?


--
thebottomline
------------------------------------------------------------------------
thebottomline's Profile: http://www.excelforum.com/member.php...o&userid=35290
View this thread: http://www.excelforum.com/showthread...hreadid=550780

  #5   Report Post  
Posted to microsoft.public.excel.misc
mrice
 
Posts: n/a
Default Basic Sorting query


Use macro-record macro on the tools menu.

Then paste into the sheet1 tab where you have selected worksheet and
activate in the boxes at the top.


--
mrice

Research Scientist with many years of spreadsheet development experience
------------------------------------------------------------------------
mrice's Profile: http://www.excelforum.com/member.php...o&userid=10931
View this thread: http://www.excelforum.com/showthread...hreadid=550780

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
changing query source [email protected] Excel Worksheet Functions 2 March 21st 06 08:55 PM
AHHH! Again JAA149 Excel Discussion (Misc queries) 0 October 31st 05 11:36 AM
AHHHH-Get Data from Multiple Excel workbooks JAA149 Excel Discussion (Misc queries) 5 October 30th 05 05:19 PM
"Query cannot be edited by the Query Wizard" PancakeBatter Excel Discussion (Misc queries) 0 April 25th 05 05:59 PM
Very basic query KiwiBrian New Users to Excel 4 December 24th 04 02:29 AM


All times are GMT +1. The time now is 11:30 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"