表单每次显示一条记录。我想,通过单击按钮,系统会在所选记录的行中的数据库表上放置一个值。就像是:
DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand write "example" in the field <FieldName> of the selected record
有可能是这样的吗?
最简单的方法是将字段绑定到文本框,然后将文本框的Visible属性设置为False。
现在,在OnClick事件中调用此代码:
Me!NameOfTextbox.Value = "example"
' Save the record.
Me.Dirty = False