2 Better answer given by "rm -rf"
source | link

I have to do this all the time. I only have an annoyingly manual way to solve this. On a mac, Alt-click on the cell marker on the right for an InputCell containing the code, this should select ALL input cells. Then go to the Cell -> Cell Properties menu at the top and unselect the Open item. All the input cells should hide. On the right there should still be tiny little input cell markers. To open them follow the same procedure and select the Open again.

At the Wolfram conference last month, this question was raised and a number of suggestions were made for implementing functions that would automate this, but I did not successfully figure out how to do it. If anyone has such a function that could be attached to a button in a floating toolbar at the top of a notebook, please post itThe answer by "rm -rf" is great! Thanks.

I have to do this all the time. I only have an annoyingly manual way to solve this. On a mac, Alt-click on the cell marker on the right for an InputCell containing the code, this should select ALL input cells. Then go to the Cell -> Cell Properties menu at the top and unselect the Open item. All the input cells should hide. On the right there should still be tiny little input cell markers. To open them follow the same procedure and select the Open again.

At the Wolfram conference last month, this question was raised and a number of suggestions were made for implementing functions that would automate this, but I did not successfully figure out how to do it. If anyone has such a function that could be attached to a button in a floating toolbar at the top of a notebook, please post it.

I have to do this all the time. I only have an annoyingly manual way to solve this. On a mac, Alt-click on the cell marker on the right for an InputCell containing the code, this should select ALL input cells. Then go to the Cell -> Cell Properties menu at the top and unselect the Open item. All the input cells should hide. On the right there should still be tiny little input cell markers. To open them follow the same procedure and select the Open again.

The answer by "rm -rf" is great! Thanks.

1
source | link

I have to do this all the time. I only have an annoyingly manual way to solve this. On a mac, Alt-click on the cell marker on the right for an InputCell containing the code, this should select ALL input cells. Then go to the Cell -> Cell Properties menu at the top and unselect the Open item. All the input cells should hide. On the right there should still be tiny little input cell markers. To open them follow the same procedure and select the Open again.

At the Wolfram conference last month, this question was raised and a number of suggestions were made for implementing functions that would automate this, but I did not successfully figure out how to do it. If anyone has such a function that could be attached to a button in a floating toolbar at the top of a notebook, please post it.