LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default Autosort, but keep Row 1 seperate

I've figured out how to autosort my columns, but there are two problems: I
can't seem to do it without messing up my frozen window pane in Row 1 (this
describes the information in the spreadsheet), and I want an "average"
formula to populate one of the cells I use in the autosort formula (It
disappears every time the autosort function kicks in).

Anyhow, here's the formula I came up with. The main problem is with the
first row being included in the sort. I thought I had it covered, but
obviously it doesn't work.

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("S2")) Is Nothing Then
Exit Sub
End If

Application.EnableEvents = False
Columns("A:S").Sort Key1:=Range("G2,k2,l2"), order1:=xlDescending
Range("A2:S2").Insert Shift:=xlDown
Application.EnableEvents = True
End Sub

Any and all help is much appreciated!
 
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
How do I seperate a full name field out into three seperate columns? Rod Excel Worksheet Functions 3 October 31st 06 08:06 PM
seperate first 2 lines of column in seperate columns in same row Glynnhamer Excel Discussion (Misc queries) 2 October 9th 06 04:23 AM
Viewing 2 seperate spreadsheets on the screen simultaneously Joe31 Excel Discussion (Misc queries) 2 March 22nd 06 05:43 PM
Excel should open workbooks in seperate windows like Word does ocaptain Excel Discussion (Misc queries) 2 June 3rd 05 04:45 PM
how do i seperate data from one column into two seperate ones in . Nikki Excel Discussion (Misc queries) 2 March 30th 05 08:31 PM


All times are GMT +1. The time now is 06:57 AM.

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

About Us

"It's about Microsoft Excel"