Tom Wellige 60 Report post Posted September 3, 2019 This post is taken from the Swyx Forum Archive (2007-2014) and was originally posted 29.08.2011 by me The following function sets the "new voicemail indication" for a certain user or all users within the user group. It makes use of the PBXConfig object which is fully described in the following Swyx knowledgebase article: Request configuration and user data (incl. user status) within an Extended Call Routing script (kb2910) Please note that it is not necessary to instantiate the PBXConfig object yourself, as it is already available in the global variable g_PBXConfig. To use the function within your call routing script just copy&paste it into the "Start" block and call it afterwards within an e.g. "Insert Script Code" block. '------------------------------------------------------------------- ' SetNewVoicemailFlag ' ' This function sets the "new voicemail indication" for a single user ' or all users of a SwyxWare user group. ' ' Parameter: ' sUserOrGroup name of user or group ' ' Return: ' '-------------------------------------------------------------------- Function SetNewVoicemailFlag ( sUserOrGroup ) PBXScript.OutputTrace "-------------> SetNewVoicemailFlag ( sUserOrGroup = " & sUserOrGroup & " )" Dim oUsers Set oUsers = g_PBXConfig.GetUserByAddress(sUserOrGroup) Dim oUser For Each oUser In oUsers PBXScript.OutputTrace "Found user " & User.Name oUser.NumberOfNewVoicemails = oUser.NumberofNewVoicemails + 1 Next PBXScript.OutputTrace "<------------- SetNewVoicemailFlag" End Function 0 Quote Share this post Link to post Share on other sites