I have a While-Loop lurking through a notebook.
I want to find out - among other things - if a cell is not visible because it is a member of a closed group.
I tried various things, see xxx below.
But maybe the CurrentValue-Aproach is not the right thing at all, maybe some FrontEndToken-thing would work.
Can someone help or point to the right thing.
Here is an example.
The fist cell is a "Chapter"-Cell, the second is a "Text"-Cell which is the "head" of a group which is closed via cell brackets double-click.
My favorite was CellOpen but it gives True in both cases.
xxx="ShowSelection"; (* Both True *)
xxx="Background"; (* Works well *)
xxx="CellOpen"; (* Both True *)
xxx="Visible"; (* Both True *)
xxx="CellGroupData"; (* Both $Failed *)
xxx="ShowClosedCellArea"; (* Both False *)
xxx="CellGroup"; (* Both $Failed *)
Row[{"Test is: ",xxx }]
SelectionMove[book,Before,Notebook];
SelectionMove[book,Next,Cell]; Last@SelectedCells[]
SelectionMove[book,Next,Cell]; Last@SelectedCells[]
CurrentValue[Last@SelectedCells[],xxx]
SelectionMove[book,Next,Cell]; Last@SelectedCells[]
CurrentValue[Last@SelectedCells[],xxx]
