# Button for expanding a cell? [duplicate]

This question already has an answer here:

How can I create a button which sits next to the cell, like so: http://i.imgur.com/ZFkgn5q.jpg

When you click the button it expands the cell, like this (note the cells on the right): http://i.imgur.com/3fyvUOJ.jpg

I can't find any code inside the Mathematica notebook for creating the button.

Duplicate of: Triangle that collapse cells

## marked as duplicate by Kuba♦, bbgodfrey, Karsten 7., Simon Woods, Bob HanlonMar 8 '15 at 22:09

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

## 1 Answer

You need to set the option ShowGroupOpener to True:

SetOptions[EvaluationNotebook[], ShowGroupOpener -> True]


You can also use $FrontEnd (resp., $FrontEndSession) instead of EvaluationNotebook[] to get the effect for the current and future front-end sessions (resp., the current session).

Alternatively, you can use the OptionInspector from the Format menu:

to set this option at theselected cell, selected notebook or global level.

• Thanks! Can I delete the cell after evaluating it? – Lightvvind Mar 7 '15 at 19:33
• @Lightvvind, you mean the cell with command SetOptions[...]? – kglr Mar 7 '15 at 19:36
• Yes, or do I need to keep it in the notebook? – Lightvvind Mar 7 '15 at 19:39
• @Lightvvind, you can make that line a self-destructing one (see, for example, this q/a). However, using the option inspector is probably easier/cleaner. – kglr Mar 7 '15 at 19:45