I want to iterate around the tabs in the XamTabcontrol and issue a close, so that they can each respond to the close and prompt the user to save changes.
I can't see an obvious way to do this....help !
If you have added TabItemEx's to the Items collection you can just iterate the collection casting to that type and then calling its ExecuteCommand method with a parameter of TabItemExCommands.Close. There is a CloseAllTabs command as well but I'm assuming that you want to stop closing if one cancels the closing whereas that command will close all that do not cancel. A more generic version of what I described above would be something like: