Jump to content
Gold Sponsor: Data-Way IT-Consulting, Austria

  • Functions

    Functions


    29 pages in this category

    1. AnyRedirectionConfigured

      VBScript   → Lua   The following function returns true if the current script user has any redirection configured (unconditional, busy or delayed). Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' AnyRedirectionConfigured ' ' Returns true if current user has configured any redirection (unconditional, busy or delayed) ' ' Parameter: ' none ' ' Return: ' boolean '--------------------
      • 0 comments
      • 138 views
    2. CheckCallerInDatabase

      VBScript   This function checks if the current caller (i.e. his phone number) can be found in a configured database. It can be used to create black or white lists for incoming calls on a user. Please see the Introduction chapter for some usage instructions.   ' CursorTypeEnum Values Const adOpenForwardOnly = 0 Const adOpenKeyset = 1 Const adOpenDynamic = 2 Const adOpenStatic = 3 ' LockTypeEnum Values Const adLockReadOnly = 1 Const adLockPessimistic = 2 Const adLockOptimi
      • 0 comments
      • 187 views
    3. CheckCallerInTextFile

      VBScript   → Lua   This function checks if the current caller (i.e. his phone number) can be found in a given text file. It can be used to create black or white lists for incoming calls on a user. Please see the Introduction chapter for some usage instructions.   ' FileOpen iomode Values Const fsoForReading = 1 ' Open a file for reading only. Const fsoForWriting = 2 ' Open a file for writing only. Const fsoForAppending = 8 ' Open
      • 0 comments
      • 251 views
    4. GetComputerName

      VBScript   This function returns the name of the computer (i.e. the host hame) the current script (i.e. the SwyxWare) is running on. Please see the Introduction chapter for some usage instructions.   ''------------------------------------------------------------------- '' Name: GetComputerName '' =============== '' '' Returns the name of the machine/computer this script (i.e. the SwyxWare) is running on. '' '' return value: '' string computer nam
      • 0 comments
      • 116 views
    5. GetFilesInFolder

      VBScript   → Lua   The following function fills an array with the names of a files in a given folder. The names contain the complete path. It can be used for example, to get a list of announcement (.wav) files in a folder to play them one after each other. See example code below... Please see the Introduction chapter for some usage instructions.   '-------------------------------------------------------------- ' GetFilesInFolder() ' ' Reads all file names in given fo
      • 0 comments
      • 87 views
    6. GetUserEMailAddress

      VBScript   → Lua   This function returns the configured email address of the given user. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' GetUserEMailAddress ' ' Returns the configured email address of the given user. ' ' Parameter: ' sNumber number or name of user ' ' Return: ' string '---------------------------------------------------------------- Function G
      • 0 comments
      • 33 views
    7. GetUserNameFromExtension

      VBScript   → Lua   The following function returns the user name from a given extension. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' GetUserNameFromExtension ' ' Returns the user name for the given extension. ' ' Parameter: ' sExtension extension ' ' Return: ' string user name '---------------------------------------------------------------- Function GetUserNameF
      • 0 comments
      • 126 views
    8. IsAtLeastOneMemberOfGroupBusy

      VBScript   → Lua   This function returns true if at least one member of the given group is busy. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsAtLeastOneMemberOfGroupBusy ' ' Returns true if at least one member of the given group is busy. ' ' Parameter: ' sGroup group number or name ' ' Return: ' boolean true - at least one member of group busy '
      • 0 comments
      • 119 views
    9. IsAtLeastOneMemberOfGroupLoggedOff

      VBScript   → Lua   This function returns true if at least one member of the given group is logged off. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsAtLeastOneMemberOfGroupLoggedOff ' ' Returns true if at least one member of the given group is logged off. ' ' Parameter: ' sGroup group number or name ' ' Return: ' boolean true - at least one member of group
      • 0 comments
      • 120 views
    10. IsCallTransferred

      VBScript   → Lua   This function returns true if the call was transferred by another user and is not a direct call. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsCallTransferred ' ' Checks if the current call was transferred to the current user, ' i.e. was in some other user's call routing before. ' ' Parameter: ' ' Return: ' boolean true - call was transferred '
      • 0 comments
      • 127 views
    11. IsExternalRedirectionConfigured

      VBScript   → Lua   This function returns true if the current script user has an unconditional redirection to an external destination enabled. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsExternalRedirectionConfigured ' ' Checks if there is an unconditional call forwarding configured to an ' external number. The function checks if the configured unconditional ' call forwarding st
      • 0 comments
      • 151 views
    12. IsGroupLoggedOff

      VBScript   → Lua   This function returns true if all members of the given group are logged off. Please see the Introduction chapter for some usage instructions.   ''------------------------------------------------------------------- '' Name: IsGroupLoggedOff '' ================ '' '' Checks if all members of a given SwyxWare user group are logged off. '' '' return value: '' integer True - all members of the given group are logged off (or statu
      • 0 comments
      • 120 views
    13. IsLoopConfigured

      VBScript   → Lua   The following function returns True if the current script user can be found in the list of users, where the current call has already been. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsLoopConfigured ' ' Checks if current script user is in the PreviousScripts list, ' i.e. the call was previously already in that user's call routing. ' So chances are high t
      • 0 comments
      • 105 views
    14. IsPublicHolidayAT

      VBScript   This function checks a given date for a public holiday in Austria. It takes the different federal states into consideration. Please see the Introduction chapter for some usage instructions.   '------------------------------------------------------------------- ' Feiertagsüberprüfung Österreich ' ' Author: Dominik Kronsteiner (PCH IT Solution GmbH - www.pch.at) ' ' Version: v1.1 - 2019-09-05 '------------------------------------------------------------------- '
      • 0 comments
      • 125 views
    15. IsPublicHolidayDE

      VBScript   → Lua   This function checks a given date for a public holiday in Germany. It takes the different federal states into consideration. Please see the Introduction chapter for some usage instructions.   ' Federal States of Germany const vb_FS_BW = 1 ' Baden-Wuerttemberg const vb_FS_BYMH = 131072 ' Bayern (mit Mariea Himmelfahrt) const vb_FS_BY = 2 ' Bayern (ohne Mariea Himmelfahrt) const vb_FS_BE = 4 ' Berlin const vb_FS_BB = 8
      • 0 comments
      • 524 views
    16. IsRedirectedFromByName

      VBScript   → Lua   This function checks if the current call was redirected by a given user. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsRedirectedFromByName ' ' Checks if current call is redirected by a given user. ' ' Parameter: ' sUserName name of user to check if call is redirected from ' ' Return: ' boolean true - call was redirected by given user '
      • 0 comments
      • 105 views
    17. IsRedirectedFromByNumber

      VBScript   → Lua   This function returns True if the call was redirected/transferred by a certain user (extension) or list of extensions, separated by ; (semikolon). Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsRedirectedFromByNumber ' ' Returns true if the current call is redirected by any of the numbers ' given in the semicolon separated list. It also returns the number that '
      • 0 comments
      • 129 views
    18. IsRedirectionLoopConfigured

      VBScript   → Lua   This function returns True if the current script user has an unconditional redirection to a user configured, where the current call already has been (in his call routing). Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsRedirectionLoopConfigured ' ' Checks if the undonditional redirection target of the script user is ' already in the PreviousScripts list, i.
      • 0 comments
      • 97 views
    19. IsUserFree

      VBScript   → Lua   This function returns true if the given user is logged in and free. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsUserFree ' ' Checks if given user is free or not. ' ' Parameter: ' sNumber extension ' ' Return: ' boolean '---------------------------------------------------------------- Function IsUserFree( sNumber ) PBXScript.Output
      • 0 comments
      • 170 views
    20. IsUserInGroup

      VBScript   → Lua   This function checks if the current script user is member of the given group. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsUserInGroup ' ' Checks if the current script user is in the given group ' ' Parameter: ' sGroup group number or name ' ' Return: ' boolean '---------------------------------------------------------------- Function
      • 0 comments
      • 134 views
    21. IsUserLoggedOff

      VBScript   → Lua   This function returns True of the given user is logged off from the server. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsUserLoggedOff ' ' Checks if given user is logged off ' ' Parameter: ' sNumber user name or extension ' ' Return: ' boolean '---------------------------------------------------------------- Function IsUserLoggedOff( sNumber ) PB
      • 0 comments
      • 176 views
    22. IsUserLoggedOn

      VBScript   → Lua   This function returns True of the given user is logged on. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' IsUserLoggedOn ' ' Checks if given user is logged on ' ' Parameter: ' sNumber user name or extension ' ' Return: ' boolean '---------------------------------------------------------------- Function IsUserLoggedOn( sNumber ) PBXScript.OutputTrace
      • 0 comments
      • 108 views
    23. LaunchCmd

      VBScript   → Lua   This function calls (launches) a given command, i.e. launches any given application. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' LaunchCmd ' ' Calls/launches the given command ' ' Parameter: ' sCommand command to be called ' ' Return: ' none '---------------------------------------------------------------- Function LaunchCmd( sCommand ) PBXSc
      • 0 comments
      • 138 views
    24. LaunchHTTPRequest

      VBScript   → Lua   This function calls (launches) a given URL (http request) and returns True if the request returns without error. Please see the Introduction chapter for some usage instructions.   '------------------------------------------------------------------- ' LaunchHTTPRequest ' ' Launches given URL. ' ' Parameter: ' sURL complete url ' ' return value: ' boolean True - request file processed ' False - request file *not* processe
      • 0 comments
      • 190 views
    25. LaunchHTTPRequestEx

      VBScript   → Lua   This function calls (launches) a given URL (http request) and returns True if the request returns without error. Please see the Introduction chapter for some usage instructions.   '------------------------------------------------------------------- ' LaunchHTTPRequestEx ' ' Launches given URL by using the Swyx Server build-in PBXScript.WebRequest ' ' Parameter: ' sURL complete url ' ' return value: ' boolean True - request returned 2
      • 0 comments
      • 84 views
    26. LogCallIntoDatabase

      VBScript   This function logs some details into a database Please see the Introduction chapter for some usage instructions.   ' CursorTypeEnum Values Const adOpenForwardOnly = 0 Const adOpenKeyset = 1 Const adOpenDynamic = 2 Const adOpenStatic = 3 ' LockTypeEnum Values Const adLockReadOnly = 1 Const adLockPessimistic = 2 Const adLockOptimistic = 3 Const adLockBatchOptimistic = 4 ' CommandTypeEnum Values Const adCmdUnknown = &H0008 Const adCmdText = &H0001 Const
      • 0 comments
      • 105 views
    27. LogCallIntoTextFile

      VBScript   → Lua   This function logs some details into a given log (text) file. Please see the Introduction chapter for some usage instructions.   ' FileOpen iomode Values Const fsoForReading = 1 ' Open a file for reading only. Const fsoForWriting = 2 ' Open a file for writing only. Const fsoForAppending = 8 ' Open a file and write to the end of the file. Const fsoDontCreateIfNotExist = False Const fsoCreateIfNotExist = True
      • 0 comments
      • 127 views
    28. SetNewVoicemailFlag

      VBScript   → Lua   The following function sets the "new voicemail indication" for a certain user or all users within a user group. Please see the Introduction chapter for some usage instructions.   '------------------------------------------------------------------- ' 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
      • 0 comments
      • 54 views
    29. UserStatus

      VBScript   → Lua   This function returns the current status of the given user. Please see the Introduction chapter for some usage instructions.   '---------------------------------------------------------------- ' UserStatus ' ' Returns the current status of the given user. ' ' Parameter ' sNumber user name or extension ' ' Return ' integer 0 - State Unavailable (no status signalling configured!) ' 1 - Logged Off '
      • 0 comments
      • 240 views
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and have taken note of our Privacy Policy.
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.