Ask Your Question

Is it possible to hide the contents of a cell, and only display the contents when a password is submitted?

asked 2017-12-05 10:29:39 +0100

jringoot gravatar image

updated 2020-10-22 12:34:10 +0100

Alex Kemp gravatar image

I would like to include sensitive information in a calc spreadsheet. Concrete case: A list of people with some sensitive information per user. When someone is in my office, I would like to give him just his personal information, but he should not see the information of others. I would like to be able to visualize just the information of this customer, when I "unlock the cell", with the password for the sheet, to show just this persons cell with his sensitive information.

Is this possible?

edit retag flag offensive close merge delete

3 Answers

Sort by » oldest newest most voted

answered 2017-12-05 23:00:31 +0100

m.a.riosv gravatar image

In such way I think not but depending on how data are organized you can use a filter to hide all cells except those you want make visible. Or linking data on other sheet with e.g. VLOOKUP() to show the data for that person without show the sheet with data.

edit flag offensive delete link more

answered 2017-12-06 15:46:12 +0100

librebel gravatar image

Hello @jringoot,

Protecting and Hiding Cells becomes only effective after the Sheet has been protected.

1. Right-click inside a cell that must be hidden, and select the menuitem "Format Cells...";
2. In the dialog that pops up, select the tab "Cell Protection";
3. Check the checkboxes "Hide All" and "Hide when printing";
4. Click OK;
5. Now Select the menu "Tools : Protect Sheet";
6. In the dialog that pops up, check the checkbox "Protect this sheet and the contents of protected cells";
7. Set password and further settings as desired, and click OK.

HTH, lib

edit flag offensive delete link more

answered 2017-12-06 15:27:16 +0100

peterwt gravatar image

When you use a password to protect a Sheet in a spreadsheet the cells that are set to be protected or protected and hidden are operated on as a group. You cannot select just say one cell to be made visible by using the password; the whole group will become unprotected.

You can however do this with a macro. I have attached a sample spreadsheet using a macro that only shows one cell. Cells B1, B2, and B3 are protected and hidden. Select one of the hidden cells and click the button and that cell will become visible but still protected so that it can be seen. When you close the spreadsheet do NOT save as this would save it with the cell you have made visible remain visible. If you want to change the data in one of the protected cells open the spreadsheet and unprotect in the normal way, make the changes and protect. The password for my example is retep, you will see it used in the macro.

You should be aware that protecting sheets with a password is not really secure. It is meant to prevent inadvertent modifications. The spreadsheet is not encrypted and can easily be seen without the password. Do not let anyone have a copy of your spreadsheet as they could see the sensitive information without the password. C:\fakepath\CalcProtect.ods

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower


Asked: 2017-12-05 10:29:39 +0100

Seen: 2,173 times

Last updated: Oct 22 '20