Forum Discussion
Persistent or auto-start teams meeting for unattended monitor
It's not immediately obvious, but the 'Join' button (in Edge) has 'focus' and can be activated by the Enter key.
This crude solution using VBS and SendKeys appears to be working at the moment (subject to further testing).
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "microsoft-edge:[ENTERURLHERE]", 9
' Give Teams time to load
WScript.Sleep 15000
WshShell.SendKeys "{ENTER}"
WScript.Sleep 10000
WshShell.SendKeys "{TAB}"
WScript.Sleep 500
WshShell.SendKeys "{TAB}"
WScript.Sleep 500
WshShell.SendKeys "{TAB}"
WScript.Sleep 500
WshShell.SendKeys "{TAB}"
WScript.Sleep 500
WshShell.SendKeys "{ENTER}"
WScript.Sleep 500
WshShell.SendKeys "{DOWN}"
WScript.Sleep 500
WshShell.SendKeys "{DOWN}"
WScript.Sleep 500
WshShell.SendKeys "{ENTER}"
I researched this question a while back, when I was trying to auto-start Zoom meetings, and came up with a solution that would likely work to start Teams meetings as well.
I wrote a four-line Windows Powershell script that:
- launches Zoom
- waits a bit
- opens the URL for the Zoom meeting
- waits a bit
- closes the browser
(Newer browsers require a confirmation—they won't go right into the meeting—so I set the default browser to be an older version of Internet Explorer that will launch and join the meeting without confirmation.)
I also wrote a one-line Powershell script that quits Zoom, to end the meeting. (I have to "force quit" Zoom, because it wants a confirmation when quitting if there's an active meeting.)
After I wrote these, I used Task Scheduler to set up "Start Meeting" and "End Meeting" tasks that run the corresponding PowerShell scripts at the designated start and end times for the meetings.
(Each computer is set up to join the same meeting room for every meeting, but you could also write multiple "start meeting" scripts with different URLs.)
That's the solution I used for Zoom, and that's the setup I'm planning on using with Teams, once we start to migrate over.
UPDATE: Hmm... This works except for it still brings up the "audio and video settings" screen, with the Join Now button, for the "host", unattended computer. I'll have to add an "enter key" press to the "start meeting" PowerShell script, to enter the meeting.
Also, our host computers are Windows 10 machines, and this won't wotk on the Mac. The Office 365 apps are AppleScript-able, though, and you could likely write scripts that would launch meetings, press the "Join Now" button, and quit Teams, and have them execute at set times.
- PaulF707Apr 25, 2020Brass Contributor
If you get this working with Teams I would really appreciate you sharing your success.
My crude script below works sometimes, but it seems that the action menus in Teams seem to vary, sometimes depending on if someone used the session previously (perhaps opened the chat window, or turned off the camera etc), and other times for no apparent reason (other than 'Microsoft') - so the Send Keys process for activating different options don't always work correctly.
I could also do with a way of stopping Edge remembering old browser windows when restarting (as I can end up with multiple Teams sessions in multiple Tabs).
- VeselinvesOct 06, 2020Copper Contributor
Could you please tell me or make a code for teams, that does the same as the one you've made for Zoom.
- jeeman150Oct 02, 2022Copper Contributor
Looking for the same thing. I want to have a meeting auto-start on Teams daily. Can you help? thanks
- jgiroux9Dec 16, 2020Copper Contributor
zanseattle Have you been able to create a script that:
- Opens a teams meeting automatically at startup in Teams app or the browser (without having to select/click to open in teams app or browser)
- Automatically click the "Join now" button at the Teams meeting splash screen
- Put the teams meeting full screen automatically