I have a Workbook with several sheets.
Sometimes more than one sheet will already be selected when it's opened.
I want to unprotect the Workbook using :
'Unprotect it if it's protected
If sht.ProtectContents = True Then
ActiveSheet.Unprotect
End If
which works fine, PROVIDED that there is only one sheet selected.
So how do i make sure in my code that only 1 sheet is selected? I will never know which sheet(s) are selected in advance, so coding the selection of one particular sheet won't always work, because, if you select a sheet which is one of (say) three selected, all three remain selected, you just change which one is active.