+ Reply to Thread
Results 1 to 11 of 11

Sorting an array

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    08-20-2009
    Location
    Plymouth, England
    MS-Off Ver
    Excel 2013
    Posts
    149

    Sorting an array

    Hi all,

    I have a problem with an array. The array pulls all the data from one spreadsheet and displays it in a standings format in another. When I try to sort the standings I get the message 'You cannot change part of an array'. Is there a way round this?

    Thanks in advance,

    Luke

  2. #2
    Valued Forum Contributor Rahul Nagar's Avatar
    Join Date
    09-18-2008
    Location
    nasik
    MS-Off Ver
    Excel 2003
    Posts
    465

    Re: Sorting an array

    Hi lukela85,

    To cancel the error message, click OK, and then click the "X" button in the formula bar (or press ESC).

    To determine which cells make up the array, use either of the following methods to highlight the range that makes up the array formula:

    * Choose one of the cells that you know is in the array formula. On the Formula menu, click Select Special, and then click Current Array. In Microsoft Excel versions 5.0 and later, follow these steps:

    1. On the Edit menu, click Go To. Or, press F5.

    2. In the Go To dialog box, click Special.

    3. In the Go To Special dialog box, click Current Array, and then click OK.

    -or-
    * Press CTRL+SHIFT and double-click a cell that you know makes up that array. After selecting the entire range that contains the array formula, edit the formula and press CTRL+SHIFT+ENTER if you are using Microsoft Excel for Windows, or COMMAND+RETURN if you are using Microsoft Excel for the Macintosh to reenter the array formula.

    Regards
    Rahul
    __________________
    Regards
    Rahul Nagar
    Founder of www.myshortcutkeys.com.


    If you get the answer of your questions then please click EDIT in your original post then click on GO ADVANCED and set the PREFIX box to SOLVED. It helps everybody! ....
    Also
    If you are satisfied by any members response to your problem please consider using the scales icon top right of thier post to show your appreciation.

  3. #3
    Forum Contributor
    Join Date
    08-20-2009
    Location
    Plymouth, England
    MS-Off Ver
    Excel 2013
    Posts
    149

    Re: Sorting an array

    Thanks for your help. I think I'm right in saying though that by doing that I only identify the range of the array. Ideally what I'm looking to do is find a way to sort my standings, and because the data is held in an array I am unable to do that at present.
    Last edited by shg; 07-05-2010 at 03:37 PM. Reason: deleted quote

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Sorting an array

    Lukela, please don't quote whole posts -- it's just clutter.

    Thanks.
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Sorting an array

    youll probably have to unique rank the standings then use a vlookup or index/ match to sort
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  6. #6
    Forum Contributor
    Join Date
    08-20-2009
    Location
    Plymouth, England
    MS-Off Ver
    Excel 2013
    Posts
    149

    Re: Sorting an array

    Quote Originally Posted by martindwilson View Post
    youll probably have to unique rank the standings then use a vlookup or index/ match to sort
    How would I go about doing this?

  7. #7
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Sorting an array

    show us your work book!

  8. #8
    Forum Contributor
    Join Date
    08-20-2009
    Location
    Plymouth, England
    MS-Off Ver
    Excel 2013
    Posts
    149

    Re: Sorting an array

    I have tried uploading my worksheet, however the uploading tool keeps crashing on me. I see the limit is a 1000Kb file, and my file is 950Kb, so even though it is slightly smaller than the upper limit I am assuming this is probably why the uploader crashes, Can I reduce the file size to allow for upload?

  9. #9
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Sorting an array

    Last edited by martindwilson; 07-07-2010 at 05:52 PM.

  10. #10
    Forum Contributor
    Join Date
    08-20-2009
    Location
    Plymouth, England
    MS-Off Ver
    Excel 2013
    Posts
    149

    Re: Sorting an array

    I have deleted some of the code so I was able to upload the worksheet, as I was having problems zipping it. It doesn't affect the standings worksheet though. Thanks for any further help
    Attached Files Attached Files

  11. #11
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Sorting an array

    bit hard to do as everything has 0 in it! look at the link in my last post for unique rank and index/match

+ 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