Note : I generated the code using "pyiuc5" in command, then tried to do job with functions Fonction_Ouvrir_Onglet_1, Fonction_Ouvrir_Onglet_2 and self.TabWidget.setCurrentIndex() method. None of these 3 attempts is working.

Okay I do not think you really want to put your Buttons on a Tab as such I have rendered a version where the Tabs are separate from the Buttons -- not sure why you are using Buttons though since clicking on the Tab itself brings it into focus?

Thak you very much for your answer. It's working perfectly and I have learned a lot through your coding style.

The reasons for the buttons in a tab are :

Other widgets are on the main menu windows

I have a lot of tabs (42 I think, corresponding to 42 data bases).

I want to be able to reach any of those tabs from that specific one by button click, and, come back there from any other tab by button click (that last button will be in the current tab I am in, redirecting to the tab containing all my buttons).

I need to understand inheritance to make my tabs communicate that way. Added to what you have provided, I think it will do.

With your description I would strongly suggest then doing away with the Tabs all together and use a Stackable Widget basically think an array of views or turning your tabs into an array and only showing the contents of the tab rather than showing the tab at all. If you need help on how to change this into a stackable widget just ask but give it a try first you will learn more from trying it than you will from being spoon fed ;)