Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Problem sorting a single column in a shared workbook
I´m using the sort method to do a simple sorting in a column. It work fine by vba sort method (Works fine sorting from menu also afte selecting a column). The single column (and only that one) is sorte ok. BUT: as soon as I share the workbook (Tools - Shar workbook... - "Allow..." check box) and do the same thing (sort by m vba sort method or from menue) ALL columns on that sheet are sorted not only the selected column. Is this a bug, or how can I get around this behaviour? Have got Excel 2000 on a Win2000 machine -- hakas ----------------------------------------------------------------------- hakask's Profile: http://www.excelforum.com/member.php...fo&userid=2519 View this thread: http://www.excelforum.com/showthread.php?threadid=38680 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Problem sorting a single column in a shared workbook
Hi post your code and we will all have a better chance of helping you! Simon -- Simon Lloyd ------------------------------------------------------------------------ Simon Lloyd's Profile: http://www.excelforum.com/member.php...fo&userid=6708 View this thread: http://www.excelforum.com/showthread...hreadid=386806 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Problem sorting a single column in a shared workbook
Well, code is not needed as the results are the same if code is used or sorting from the menue, but here is a quick example code: Say that you have data ("SORT") in F column and data numeric (1234) in G column: Row 4: S : 1 Row 5: O : 2 Row 6: R : 3 Row 7: T : 4 Call a simple sub: Sub sortColData() Range("F4:F7").Select Selection.Sort Key1:=Range("F4"), Order1:=xlAscending, Header:=xlGuess, _ OrderCustom:=1, MatchCase:=False, Orientation:=xlSortColumns End Sub The result is: Row 4: O : 1 Row 5: R : 2 Row 6: S : 3 Row 7: T : 4 Fine! But in a shared workbook the result is: Row 4: O : 2 Row 5: R : 3 Row 6: S : 1 Row 7: T : 4 Same code (or same menue choice), but different results. -- hakask ------------------------------------------------------------------------ hakask's Profile: http://www.excelforum.com/member.php...o&userid=25190 View this thread: http://www.excelforum.com/showthread...hreadid=386806 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Sorting Datain a Shared Workbook | Excel Discussion (Misc queries) | |||
Sorting in a shared workbook | Excel Discussion (Misc queries) | |||
Sorting Shared Workbook | Excel Discussion (Misc queries) | |||
Sorting in Shared Workbook | Excel Worksheet Functions | |||
Sorting in a shared workbook | Excel Discussion (Misc queries) |