Domino Code Fragment

Code Name*
How do you change the new mail tune under NT?
Date*
04/28/2024
Source (or email address if you prefer)*
Rlatulippe@romac.com
IP address:.3.144.127.232
Description*
How do you change the new mail tune under NT?
Type*
LotusScript
Categories*
(Misc)
Implementation:
Required Client:
Server:
Limitations:
Comments:
Files/Graphics attachments (if applicable): Code:
You can add this to a button you can send to your users (note the hardcoded
.wav file path though):

Sub Click(Source As Button)
' by Lance I. Zakin
    Dim session As New NotesSession
    Dim fileName As String
    Dim choice As String
    Dim verify As String
    Dim Path As String


     fileName = Dir("C:\WINNT\MEDIA\*.WAV")
    Path = "C:\WINNT\MEDIA\"


     Print fileName
    choice = Inputbox$("Click OK to install, otherwise CANCEL to select
another Tune.", "Install New Mail Tune", Path & FileName)


     Do While fileName <> "" And choice = ""
         fileName = Dir()
         Print Path & fileName
         choice = Inputbox$("Click OK to install, otherwise CANCEL to select
another Tune.", "Install New Mail Tune", Path & FileName)
    Loop


     Call session.SetEnvironmentVar( "NewMailTune",  choice, True)

     Msgbox "Completed!  Restart Notes to initiate " & choice & " as your New
Mail Tune.", , "Install New Mail Tune"
    Print "Restart Notes to initiate " & choice & " as your New Mail Tune."
End Sub