Public Sub SetConnectionControl(Optional intValue As Integer = 2) 'Set intValue = 1 to disallow additional user connections 'Set intValue = 2 to allow additional user connections If intValue = 1 Or intValue = 2 Then CurrentProject.Connection.Properties("Jet OLEDB:Connection Control") = intValue Else Error 9 'Subscript out of range End If End Sub