Hi,

This question has actually been asked, but I am not sure what was the context of it.
Also, the solution in that thread is not clear, so I will ask the question again with my context.

In a QTabWidget, I want the tab buttons to be enabled, but the tab switching needs to be prevented for some tabs.
The use of this is in the below scenario.

There are two tabs - "User" and "Admin".
When "Admin" is clicked, a dialog/popup to ask for user name and password needs to be displayed, and only on successful login, tab should change to Admin.
But "User" tab can be clicked and User screen should be displayed.
If I disable the "Admin" Tab, I cannot click it to show the popup.
And if I don't block the opening of Admin tab page, unauthorized viewing will be there.

Can anyone please suggest me how to proceed.

Is there any event that leads to TabChange (i.e. before the Tab is changed)

Regards,
Ash