<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2719.2200" name=GENERATOR></HEAD>
<BODY style="MARGIN-TOP: 2px; FONT: 10pt MS Sans Serif; MARGIN-LEFT: 2px">
<DIV>Here's the code I finally figured out to allow the user to define a
range:</DIV>
<DIV> </DIV>
<DIV>Dim UserRange As Range</DIV>
<DIV> </DIV>
<DIV> Prompt = "Select the rows to be
sorted."<BR> Title = "Sort Rows"<BR>
<BR> On Error Resume Next<BR> Set UserRange
= Application.InputBox( _<BR>
Prompt:=Prompt, _<BR> Title:=Title,
_<BR> Default:=ActiveCell.Address,
_<BR> Type:=8)</DIV>
<DIV> </DIV>
<DIV> <BR> Range(UserRange,
ActiveCell.Offset(0, 17)).Select<BR> Selection.Sort
Key1:=Range("F9"), Order1:=xlAscending, Key2:=Range("E9")
_<BR> , Order2:=xlAscending,
Header:=xlGuess, OrderCustom:=1, MatchCase:=
_<BR> False,
Orientation:=xlTopToBottom<BR> Application.Goto
Reference:="bottom"<BR> <BR>End Sub</DIV>
<DIV> </DIV>
<DIV>I adapted some code I found at The Spreadsheet Page website by John
Walkenbach - j-walk.com/ss/ - to give appropriate credit.</DIV>
<DIV> </DIV>
<DIV>Thanks for everyone's suggestions.</DIV></BODY></HTML>