Hi,
Can someone please help me, I am trying to write a called sub (I need a sub because I also want to do some other things) to Sort a worksheet based on the crieria in two columns.
What I have is:
(a) A column (A:A) containing a mix of up to 500 numbers (1 to 3 digit) and a few text entries (1 to 6 char). These form the basis of a movement log where say 100 different drivers (each with unique identity) are logged in and out, so there will be duplicates.
(b) A number of other columns logging task/times etc but the one I am interested in (B:B), contains a tick (marlett font "a") to denote the driver has departed.
So what I simply want to do is to sort all the rows with a "tick" in Column B to the top and have these sorted in ascending order based on Column A.
Then all the rows with no "tick" in Column B to the bottom and have these sorted in ascending order based on Column A.
The cell range to sort is A7 to J500 (cells A1 to J6 are fixed and contain overview stats)
I have found a number of threads in the forum on "sorting" but they all involve quite complex scenarios and I cannot get my head round the basics.
Thanks and Regards,
Mike
Can someone please help me, I am trying to write a called sub (I need a sub because I also want to do some other things) to Sort a worksheet based on the crieria in two columns.
What I have is:
(a) A column (A:A) containing a mix of up to 500 numbers (1 to 3 digit) and a few text entries (1 to 6 char). These form the basis of a movement log where say 100 different drivers (each with unique identity) are logged in and out, so there will be duplicates.
(b) A number of other columns logging task/times etc but the one I am interested in (B:B), contains a tick (marlett font "a") to denote the driver has departed.
So what I simply want to do is to sort all the rows with a "tick" in Column B to the top and have these sorted in ascending order based on Column A.
Then all the rows with no "tick" in Column B to the bottom and have these sorted in ascending order based on Column A.
The cell range to sort is A7 to J500 (cells A1 to J6 are fixed and contain overview stats)
I have found a number of threads in the forum on "sorting" but they all involve quite complex scenarios and I cannot get my head round the basics.
Thanks and Regards,
Mike