Dynamic Sort Macro

C

Chris

I need to create a macro and assign it to a button that
selects a named range and sorts. The issue is that the
sort key (Column) needs to be a prompted name from the
column headers. There are 12 column headers that could be
used. Likewise, the ascending or descending option needs
to be prompted. The idea is the user would click the sort
macro button, be prompted for one of the column headers
and then be prompted for ascending ro descending.

Thanks in advance.
 
T

Tom Ogilvy

Why not use the built-in dialog:

Range("NamedRange").Select
application.Dialogs(xlDialogSort).show
 

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