Python Forum
How to open a new tab without focusing on it.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to open a new tab without focusing on it.
#1
Hello everyone,

i have a project where i want to copy multiple elements on a website and each time i copy it a new tab opens with a search for this product. Unfortunatly each time i excetue it my focus switches to the new tab and i have to reclick to my initial page. Is there a way to silently open a new tab without generating the focus to it. I tryed with autoritation as False but it did not change anything. The line of code i use to open is down below. Thanks so much in advance!

webbrowser.open(ulr)
Reply
#2
Hey. Isn't there an option webbrowser.opentab(url) that will open it without focusing? Have you read the webbrowser documentation it has a lot of info
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020