错误信息:"This Action was Cancelled by an Associated Object.(3426)"
编号:QA002276
建立日期: 1999年12月17日 最后修改日期:1999年12月17日
所属类别:
Yang Fang:
Operating system: windows95
VB6.0
I have problem with database.In my project some reason I have to use combobox bound with database. I use loop in form load event to add diagnosis field of the datDx to combo list like following.
Private Sub Form_Load()
datDx.DatabaseName = app.path +"Dx.med"
datDx.RecordSource = "SELECT diagnosis FROM dx"
datDx.Refresh
Do Until datDx.Recordset.EOF
cboCC.AddItem datDx.Recordset.Fields("Diagnosis").Value
datDx.Recordset.MoveNext
Loop
End sub
no problem here, but I type new thing in combo text and try to add it to datDx.mdb like follow:
cmdAddNew_click()
With datDx
.Recordset.AddNew
.Recordset.Fields("diagnosis").Value = cboCC.Text
.Recordset.Update
End With
End Sub
I got error 3426 " This action was cancelled by an associated object" I can't find where bug is. Please help me.
Thanks a lot. Sorry I only can read chinese but can't write in my computer.
回答:
参考:微软的Knowledge Base的文章:“Q189851 RB: "This Action was Cancelled by an Associated Object.(3426)"”。
此问题由李海回答。
| |
|
|
| |
|
|