sorting names alphabetically when names may start with numbers

J

John Smith

Anyway to sort names alphabetically when names may start with
numbers?

I have a list of name of chemicals. The names may start with
numbers, like 1,2-dichlorobutane. Right now, if I sort the list,
the names start with numbers would be on the top. How do I make it
ignore nubmers and sort alphabetically?
 
G

Guest

I have a list of name of chemicals. The names may start with
numbers, like 1,2-dichlorobutane. Right now, if I sort the list,
the names start with numbers would be on the top. How do I make it
ignore nubmers and sort alphabetically?
-----------

I'm not aware of any way to do that directly. If it were me, I'd create
a new column that has the numbers stripped off and then just sort on
that column. Your example shows a "-" between the numbers and letters.
If all your names are formatted like that then it's easy to strip off
the numbers from A1 by:

[A2] = right(a1,len(a1)-find("-",a1))

Otherwise, if you can't rely on that hyphen, then I'd personally have to
give up and write some kind of VBA routine to strip off the numbers.
Perhaps someone else here will have a more inspired suggestion.

Good luck...

Bill
 
G

GORDON SCALES via OfficeKB.com

Hi,

You need to insert a line at the top of your list and type in the header
names as you described. make sure there are no blank lines in your list.

Select any cell in your list (preferably the column you want to sort by)
then select Data, then sort. Make sure "my list has header row" is checked,
then you should have your header row names in the sort by drop down lists.

Good luck
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top