We’d like to remind Forumites to please avoid political debate on the Forum.

This is to keep it a safe and useful space for MoneySaving discussions. Threads that are – or become – political in nature may be removed in line with the Forum’s rules. Thank you for your understanding.

📨 Have you signed up to the Forum's new Email Digest yet? Get a selection of trending threads sent straight to your inbox daily, weekly or monthly!
The Forum now has a brand new text editor, adding a bunch of handy features to use when creating posts. Read more in our how-to guide

Locking rows together in excel worksheet

I'm not at all a technical person, so would appreciate any answers in easy format.

On my excel spreadsheet I have my data spread across five horizontal cells. (A to E). I know how to sort the normal way by highlighting everything then choosing the "no header" box, then the sort option for the appropriate column. However, this morning I inadvertently missed out column E, and sorted a number of times (and saved the spreadsheet), before realising that column E had not been included. Now my spreadsheet is all up the creek and I will have to re-enter the data. It's a two page length spreadsheet and will take ages.

I know I should have made a back up before I embarked on the exercise but it's too late now. A lesson to me.

My questions are:

1 - After saving a document, is it possible to retrieve an earlier version?

2 - Is there a definitive way of locking horizontal cells together so that no matter which column is sorted, the data in the horizontal row always stays together so that the sort of mistake I made does not occur? (I also need to be able to change data in any one cell from time to time).

I've googled question two, and seen the same question, but no satisfactory answer anywhere.

Many thanks in advance.

Comments

  • rmg1
    rmg1 Posts: 3,159 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    As a regular user of Excel, I can't think of any way of doing what you ask (you can't go back to a previously saved version of the spreadsheet unless you have version numbers in the filename).
    Can you re-sort the data including column E to sort out the problem?

    ::edit::

    Just a thought, if the ranges are going to be static, can you use named ranges?
    :wall: Flagellation, necrophilia and bestiality - Am I flogging a dead horse? :wall:

    Any posts are my opinion and only that. Please read at your own risk.
  • darich
    darich Posts: 2,145 Forumite
    Part of the Furniture 1,000 Posts Combo Breaker
    Depends on how techie you are.....you could write a macro.
    The macro would always sort the same cells without you having to highlight them. The downside is that it wil always be the same cells ie if the macro sorts cells a1:e1 then if you add rows above and push your five "linked" rows down, the macro will still sort a1:a5. It is easy to adjust the macro though.

    Keen photographer with sales in the UK and abroad.
    Willing to offer advice on camera equipment and photography if i can!
  • Which version of windows? , in Explorer right click on the spreadsheet and see if you can retrieve earlier version? there might one from your last restore point. Failing that a recovery program eg recuva might find a deleted version but I tried that for my OH yesterday with a spreadsheet and after 2 hours of deep scan found nothing.
    Also in respect of backups etc it might be worth using microsoft sync toy and schedule a daily copy for the future
    4.8kWp 12x400W Longhi 9.6 kWh battery Giv-hy 5.0 Inverter, WSW facing Essex . Aint no sunshine ☀️ Octopus gas fixed dec 24 @ 5.74 tracker again+ Octopus Intelligent Flux leccy

    CEC Email energyclub@moneysavingexpert.com
  • rmg1
    rmg1 Posts: 3,159 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    The macro route could be good. Easy to write (just record one to start with) and then you could hit one button and it'll all be done for you.
    I can do those as well, so if you let know if you want to go that route, I'll help all I can.
    :wall: Flagellation, necrophilia and bestiality - Am I flogging a dead horse? :wall:

    Any posts are my opinion and only that. Please read at your own risk.
  • As far as linking the cells I will think about that but when i sort my data I always select all ie put the mouse over the top left box over row 1 and left of column A
    4.8kWp 12x400W Longhi 9.6 kWh battery Giv-hy 5.0 Inverter, WSW facing Essex . Aint no sunshine ☀️ Octopus gas fixed dec 24 @ 5.74 tracker again+ Octopus Intelligent Flux leccy

    CEC Email energyclub@moneysavingexpert.com
  • Thank you all so much for your swift replies. I've printed off everything and am going through your suggestions one by one. I'll get back later on to let you know how things are going.

    For the future, it has been a revelation to me that it is not necessary to physically highlight boxes; that it can be done in one stroke by clicking on the cell on the top left box over row 1 and left of Column A - makes me wonder what other long-winded ways I have of doing things!

    I also wonder why I have never thought of saving the spreadsheet as a different version each time I make alterations - that at least would ensure that any mistakes could be quickly rectified by reversion to a previous copy!

    Not sure what a macro is unfortunately - obviously I'm way down in the technical field - product of my age I fear.

    Really glad I came onto this site!!!

    Thanks
  • margo300 wrote: »
    Thank you all so much for your swift replies. I've printed off everything and am going through your suggestions one by one. I'll get back later on to let you know how things are going.

    For the future, it has been a revelation to me that it is not necessary to physically highlight boxes; that it can be done in one stroke by clicking on the cell on the top left box over row 1 and left of Column A - makes me wonder what other long-winded ways I have of doing things!

    I also wonder why I have never thought of saving the spreadsheet as a different version each time I make alterations - that at least would ensure that any mistakes could be quickly rectified by reversion to a previous copy!

    Not sure what a macro is unfortunately - obviously I'm way down in the technical field - product of my age I fear.

    Really glad I came onto this site!!!

    Thanks
    :wave: Welcome , we aim to please, come back and see us regularly
    4.8kWp 12x400W Longhi 9.6 kWh battery Giv-hy 5.0 Inverter, WSW facing Essex . Aint no sunshine ☀️ Octopus gas fixed dec 24 @ 5.74 tracker again+ Octopus Intelligent Flux leccy

    CEC Email energyclub@moneysavingexpert.com
  • rmg1
    rmg1 Posts: 3,159 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    Glad to help, we all have to start somewhere.
    A macro is just a way of recording what you do so you can do it again a bit quicker and automatically. Once you get your head round them, they're quite straightforward. If not, shout up and we'll all chip in.
    :wall: Flagellation, necrophilia and bestiality - Am I flogging a dead horse? :wall:

    Any posts are my opinion and only that. Please read at your own risk.
  • If you have a regular data range i.e no blank columns or rows in the middle of your data , you dont need to select the range at all, as excel will do it for you. The best way is just to have a single cell selected within the range - excel will then automatically select your range - which you can adjust if necessary.

    I would suggest that highlighting all cells is NOT a good way to go particularly if you are using a spreadsheet designed by someone else as there could be data elsewhere in the spreadsheet that you are screwing up.
  • chateauneufdupape
    chateauneufdupape Posts: 520 Forumite
    edited 20 February 2010 at 6:38PM
    A macro repeats a series of actions that you have recorded. Quite easy to do. So in your case, you would start the macro recording, highlight the cells you want to sort, sort the cells and then stop recording the macro. Next time you want to do a sort, all you need to do is run the macro.

    You wil find the macro in tools>macro>record new macro. Try using one on a different unimportant spread sheet until you get the hang of it.

    Once you are familiar with recording macros, you can then put a button on your spread sheet to make it very easy to run the macro.
This discussion has been closed.
Meet your Ambassadors

🚀 Getting Started

Hi new member!

Our Getting Started Guide will help you get the most out of the Forum

Categories

  • All Categories
  • 353.5K Banking & Borrowing
  • 254.1K Reduce Debt & Boost Income
  • 455K Spending & Discounts
  • 246.6K Work, Benefits & Business
  • 602.9K Mortgages, Homes & Bills
  • 178.1K Life & Family
  • 260.6K Travel & Transport
  • 1.5M Hobbies & Leisure
  • 16K Discuss & Feedback
  • 37.7K Read-Only Boards

Is this how you want to be seen?

We see you are using a default avatar. It takes only a few seconds to pick a picture.