Private Sub But38_Click()
If But38.Caption = "增加" Then
Dim ctr As Control
For Each ctr In Me.sonfrm.Form
If ctr.Type = TextBox Then
With ctr
.Locked = flase
End With
End If
Next ctr
(就是这段红色代码出问题,我希望让所有的文本框属性变为可写,请大虾帮助)
With But38
.Caption = "保存"
.ForeColor = 255
End With
Me.sonfrm.Form.DataEntry = True
Me.sonfrm.Locked = False
Else
Me.sonfrm.Locked = True
Me.sonfrm.Form.DataEntry = False
' docmd.RunSQL ""
With But38
.Caption = "增加"
.ForeColor = 0
End With
End If
End Sub
[此贴子已经被作者于2006-5-31 13:56:17编辑过]
|