Set datacombol.datasource=rs中更新问题与解决办法

      ADO 2008-6-28 18:12

set  datacombol.rowsource=rs1
set   datacombol.datasource=rs2

当点击datacombol时 调用rs2.update 时rs2不更新.
解决办法rs2.move 1 再调用update 然后再rs2.move -1

Public Sub save_Click()
    On Error GoTo doerr
    command = "save"
    RaiseEvent saveclick
    If m_recordset Is Nothing Then Exit Sub
    m_recordset.Move 1   'datacombol bug
    m_recordset.UpdateBatch
    m_recordset.Move -1
    MsgBox ("修改成功!")
     add.Enabled = True
     modify.Enabled = True
     del.Enabled = True
     save.Enabled = False
    Exit Sub
doerr:
    MsgBox ("数据格式不对" & Err.Description)
End Sub

标签集:TAGS:
回复Comments() 点击Count()

回复Comments

{commentauthor}
{commentauthor}
{commenttime}
{commentnum}
{commentcontent}
作者:
{commentrecontent}