Want teams status “Available” always?

Premkumar Arumugam
2 min readOct 21, 2022

Are you an IT professional who uses the Microsoft teams app for communication? Then, you might have worried about the status!

Even when you’re idle for a few minutes, the status will change to “away” and someone from your team may think that you went for a break or somewhere else. Is there any solution to make it available always?

Well, You can install the team’s app on your mobile and always make it available. What if there is an automation script that does this job without any human interaction? Follow the steps below to do this:

  1. Open notepad, paste the below VBScript, and save the file with the .vbs extension
Dim objShell, lngMins, flag 
Set objShell = CreateObject("WScript.Shell")
'Create a Windows Scripting Host (WSH) automation object / run an external command

lngMins = InputBox("APK! How long you want to keep your system awake?" & Replace(Space(5), " ", vbNewLine) & "Enter minutes:", "Awake Duration")
'we are replacing 5 spaces with new lines

If lngMins = vbEmpty Then
'If the user opts to cancel the process
'Do nothing

Else
On Error Resume Next
Err.Clear
flag = False
lngMins = CLng(lngMins) 'converts to type Long
If Err.Number = 0 Then 'input is numeric
If lngMins > 0 Then 'input is greater than zero
For i = 1 To lngMins
WScript.Sleep 60000 '60 seconds
objShell.SendKeys "{SCROLLLOCK 2}"
'Sending Scroll Lock keys to make windows remain unlocked state
Next

flag = True
MsgBox "Yov, Time up! Now, get back into the business!!", vbOKOnly+vbInformation, "Task Completed"
End If
End If
On Error Goto 0
If flag = False Then
MsgBox "Incorrect input, script won't run" & vbNewLine & "You can only enter a numeric value greater than zero", vbOKOnly+vbCritical, "Task Failed"
End If
End If
Set objShell = Nothing
Wscript.Quit 0

2. When you open this script, the below window shall pop up.

Initial Startup Screen
Initial Startup Screen

3. Mention the duration in minutes and Click OK. After the time expires, you’ll get a notification as shown below.

Time Expiration Screen
Time Expiration Screen

You can also schedule this vbScript in windows Task Scheduler so that it runs automatically without you manually opening it every time. I hope this solution helps you!

Note: This script will not work during power off and the user logs off.

--

--