Is it possible to hide (not remove) a PivotItem?

Viewed 3660

I have a situation where I am showing a set of PivotItems and (depending on the situation) a favorites one.

I need to be able to hide this pivot when the List containing my favorites is empty - yet it needs to show up when there is something there.

Now, I could just remove it, but what about this scenario:

  1. Go to the pivot view (no favorite-pivot, since the list is empty)
  2. Go to one of the remaining PivotItems and select an item.
  3. Select that item as a favorite in its own view
  4. Tap the back-button, and return to the pivot-view.

Now there will be no favorites-pivot, and that just isn't good enough.

I have tried to remove it with Visibility="hidden", but VS is complaining about the data context not being specified properly (it is.)

Any ideas?

2 Answers
Related