+ Reply to Thread
Results 1 to 3 of 3

Sorting problem

  1. #1
    Francine
    Guest

    Sorting problem

    I am trying to get column H ansd I to sort as the others are doing
    using a
    macro (see below).
    Using the CTRL + H function I get the find and replace feature popping
    up. How do I get it to sort properly using CTRL + H?
    Based on the same formula my other columns d-g sort properly. Any
    advice is appreciated. I whish not to use the CTRL+SHIFT+H etc.


    Sub Macro5()
    '
    ' Macro1 Macro
    ' Macro created 06/09/2006


    ' Keyboard Shortcut: Ctrl+h
    '
    Range("C13:H58").Select
    Range("H13").Activate
    Selection.Sort Key1:=Range("H13"), Order1:=xlDescending,
    Header:=xlNo, _
    OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _

    DataOption1:=xlSortNormal
    Range("G7").Select
    End Sub


  2. #2
    Zone
    Guest

    Re: Sorting problem

    You do not say which version of Excel you're using. In my version
    (2002), assigning a shortcut key to a macro overrides the built-in
    function of that shortcut key. Therefore, if you go to menu Tools,
    then Macro, then Macros and select the macro from the list, then click
    Options and set the shortcut key to h, Ctrl-h will run the macro and
    not find/replace. Are you sure you're putting in a small h and not a
    capital H?
    James

    Francine wrote:
    > I am trying to get column H ansd I to sort as the others are doing
    > using a
    > macro (see below).
    > Using the CTRL + H function I get the find and replace feature popping
    > up. How do I get it to sort properly using CTRL + H?
    > Based on the same formula my other columns d-g sort properly. Any
    > advice is appreciated. I whish not to use the CTRL+SHIFT+H etc.
    >
    >
    > Sub Macro5()
    > '
    > ' Macro1 Macro
    > ' Macro created 06/09/2006
    >
    >
    > ' Keyboard Shortcut: Ctrl+h
    > '
    > Range("C13:H58").Select
    > Range("H13").Activate
    > Selection.Sort Key1:=Range("H13"), Order1:=xlDescending,
    > Header:=xlNo, _
    > OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
    >
    > DataOption1:=xlSortNormal
    > Range("G7").Select
    > End Sub



  3. #3
    Francine
    Guest

    Re: Sorting problem

    Zone, thanks. I did not specify which version (office xp) but you
    helped with my issue I didn't know about the options to set the
    shortcut to ctrl +h. You saved me alot of headache, and now it works.

    Thanks again.



    Zone wrote:
    > You do not say which version of Excel you're using. In my version
    > (2002), assigning a shortcut key to a macro overrides the built-in
    > function of that shortcut key. Therefore, if you go to menu Tools,
    > then Macro, then Macros and select the macro from the list, then click
    > Options and set the shortcut key to h, Ctrl-h will run the macro and
    > not find/replace. Are you sure you're putting in a small h and not a
    > capital H?
    > James
    >
    > Francine wrote:
    > > I am trying to get column H ansd I to sort as the others are doing
    > > using a
    > > macro (see below).
    > > Using the CTRL + H function I get the find and replace feature popping
    > > up. How do I get it to sort properly using CTRL + H?
    > > Based on the same formula my other columns d-g sort properly. Any
    > > advice is appreciated. I whish not to use the CTRL+SHIFT+H etc.
    > >
    > >
    > > Sub Macro5()
    > > '
    > > ' Macro1 Macro
    > > ' Macro created 06/09/2006
    > >
    > >
    > > ' Keyboard Shortcut: Ctrl+h
    > > '
    > > Range("C13:H58").Select
    > > Range("H13").Activate
    > > Selection.Sort Key1:=Range("H13"), Order1:=xlDescending,
    > > Header:=xlNo, _
    > > OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
    > >
    > > DataOption1:=xlSortNormal
    > > Range("G7").Select
    > > End Sub



+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1