Access 2003
Run-time error 438. Object does not support this property or method.
///////////////////////////////////////
Public Sub Public_Disable_Text_Boxes(Form_Name, Public_Department_Name)
Dim frm As Form
Dim ctl As Control
Set frm = Form_Name
Select Case Public_Department_Name
Case "Purchasing"
For Each ctl In frm.Controls
If Val(ctl.Index) >= 0 And Val(ctl.Index) <= 40 Then
ctl.Enabled = True
Else
ctl.Enabled = False
End If
Next ctl
End Select
End Sub
Run-time error 438. Object does not support this property or method.
///////////////////////////////////////
Public Sub Public_Disable_Text_Boxes(Form_Name, Public_Department_Name)
Dim frm As Form
Dim ctl As Control
Set frm = Form_Name
Select Case Public_Department_Name
Case "Purchasing"
For Each ctl In frm.Controls
If Val(ctl.Index) >= 0 And Val(ctl.Index) <= 40 Then
ctl.Enabled = True
Else
ctl.Enabled = False
End If
Next ctl
End Select
End Sub