Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 46
Default sorting data from one tab on another

I have a spread sheet with a list of users sorted alphabetically. I'd like
to sort that data by userID on a different tab. Problem is, I don't want to
manually do it. Is there a way to have the 'ID sorted tab' automatically
update and sort itself as I make changes to the 'alphabetical tab'?

Thanks for your help!
  #2   Report Post  
Posted to microsoft.public.excel.setup
external usenet poster
 
Posts: 11,058
Default sorting data from one tab on another

Put this in Worksheet code for Sheet1:

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Range("A:A"), Target) Is Nothing Then
Exit Sub
End If
Application.EnableEvents = False
Sheets("sorted").Range("A:A").Clear
Sheets("Sheet1").Range("A:A").Copy Sheets("sorted").Range("A1")
Sheets("sorted").Range("A:A").Sort key1:=Sheets("sorted").Range("A1")
Application.EnableEvents = True
End Sub


Whenever data is changed in column A in Sheet1, the data is automatically
copied over to sheet "sorted" and sorted.
--
Gary''s Student - gsnu200718
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
Sorting data Maback Excel Discussion (Misc queries) 2 October 3rd 06 09:41 AM
Sorting data to match existing data Jack C Excel Discussion (Misc queries) 4 May 24th 06 09:48 AM
sorting data with ; jason2444 Excel Discussion (Misc queries) 3 April 12th 06 04:19 PM
colors of bar charted data don't follow data after sorting Frankgjr Charts and Charting in Excel 2 January 17th 06 12:33 PM
Need help Sorting data monkeytrader Excel Worksheet Functions 2 February 21st 05 04:34 AM


All times are GMT +1. The time now is 06:43 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"